Commit 1f62467b authored by Peter Leitzen's avatar Peter Leitzen

Fix some warnings "shadowing outer local variable"

1. ee/app/models/ee/namespace.rb:90
2. ee/app/models/ee/namespace.rb:102
3. ee/app/models/ee/project.rb:520
parent c9ef9a8a
......@@ -87,8 +87,8 @@ module EE
return false unless ::Feature.enabled?(feature, default_enabled: true)
available_features = strong_memoize(:feature_available) do
Hash.new do |h, feature|
h[feature] = load_feature_available(feature)
Hash.new do |h, f|
h[f] = load_feature_available(f)
end
end
......@@ -99,8 +99,8 @@ module EE
return true if ::License::ANY_PLAN_FEATURES.include?(feature)
available_features = strong_memoize(:features_available_in_plan) do
Hash.new do |h, feature|
h[feature] = (plans.map(&:name) & self.class.plans_with_feature(feature)).any?
Hash.new do |h, f|
h[f] = (plans.map(&:name) & self.class.plans_with_feature(f)).any?
end
end
......
......@@ -517,8 +517,8 @@ module EE
return false unless ::Feature.enabled?(feature, user, default_enabled: true)
available_features = strong_memoize(:licensed_feature_available) do
Hash.new do |h, feature|
h[feature] = load_licensed_feature_available(feature)
Hash.new do |h, f|
h[f] = load_licensed_feature_available(f)
end
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment