mirror of
https://github.com/puma/puma.git
synced 2022-11-09 13:48:40 -05:00
Switch from inject to each in config_ru_binds iteration
This commit is contained in:
parent
69449dc23a
commit
4308cd84d9
1 changed files with 3 additions and 3 deletions
|
@ -104,9 +104,9 @@ module Puma
|
||||||
rack_app, rack_options = Puma::Rack::Builder.parse_file(rackup)
|
rack_app, rack_options = Puma::Rack::Builder.parse_file(rackup)
|
||||||
@options.merge!(rack_options)
|
@options.merge!(rack_options)
|
||||||
|
|
||||||
config_ru_binds = rack_options.inject([]) do |b, (k, v)|
|
config_ru_binds = []
|
||||||
b << v if k.to_s.start_with?("bind")
|
rack_options.each do |k, v|
|
||||||
b
|
config_ru_binds << v if k.to_s.start_with?("bind")
|
||||||
end
|
end
|
||||||
@options[:binds] = config_ru_binds unless config_ru_binds.empty?
|
@options[:binds] = config_ru_binds unless config_ru_binds.empty?
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue