We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 31f3b0d commit 488ccbaCopy full SHA for 488ccba
bundler/lib/bundler/settings.rb
@@ -100,10 +100,12 @@ def initialize(root = nil)
100
def [](name)
101
key = key_for(name)
102
103
- values = configs.values
104
- values.map! {|config| config[key] }
105
- values.compact!
106
- value = values.first
+ value = nil
+ configs.each do |_, config|
+ value = config[key]
+ next if value.nil?
107
+ break
108
+ end
109
110
converted_value(value, name)
111
end
@@ -314,7 +316,7 @@ def key_for(key)
314
316
private
315
317
318
def configs
- {
319
+ @configs ||= {
320
:temporary => @temporary,
321
:local => @local_config,
322
:env => @env_config,
0 commit comments