From 30c12cad08c22a40f89201882ec19f9ca587339d Mon Sep 17 00:00:00 2001 From: Nate Berkopec Date: Thu, 9 Feb 2017 07:05:45 -0700 Subject: [PATCH] Revert "fix access priorities of each level in LeveledOptions" This reverts commit 15f0847289d0815284f87eeea4625100b581c026. Fixes #1200 --- lib/puma/configuration.rb | 2 +- test/test_config.rb | 11 ----------- 2 files changed, 1 insertion(+), 12 deletions(-) diff --git a/lib/puma/configuration.rb b/lib/puma/configuration.rb index 850d55f603..116ded2815 100644 --- a/lib/puma/configuration.rb +++ b/lib/puma/configuration.rb @@ -31,7 +31,7 @@ def shift end def [](key) - @set.reverse_each do |o| + @set.each do |o| if o.key? key return o[key] end diff --git a/test/test_config.rb b/test/test_config.rb index 2290ebb47e..6d3feb52e0 100644 --- a/test/test_config.rb +++ b/test/test_config.rb @@ -56,17 +56,6 @@ def test_allow_users_to_override_default_options assert_equal 'bin/rails server', conf.options[:restart_cmd] end - def test_overwrite_options - conf = Puma::Configuration.new do |c| - c.workers 3 - end - conf.load - - assert_equal conf.options[:workers], 3 - conf.options[:workers] += 1 - assert_equal conf.options[:workers], 4 - end - private def with_env(env = {})