aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--actionpack/lib/action_dispatch/middleware/remote_ip.rb4
-rw-r--r--actionpack/test/dispatch/routing_test.rb4
2 files changed, 4 insertions, 4 deletions
diff --git a/actionpack/lib/action_dispatch/middleware/remote_ip.rb b/actionpack/lib/action_dispatch/middleware/remote_ip.rb
index 66ece60860..030ccb2017 100644
--- a/actionpack/lib/action_dispatch/middleware/remote_ip.rb
+++ b/actionpack/lib/action_dispatch/middleware/remote_ip.rb
@@ -33,8 +33,8 @@ module ActionDispatch
class GetIp
def initialize(env, middleware)
- @env = env
- @middleware = middleware
+ @env = env
+ @middleware = middleware
@calculated_ip = false
end
diff --git a/actionpack/test/dispatch/routing_test.rb b/actionpack/test/dispatch/routing_test.rb
index d5c1586600..e5ed11d1ea 100644
--- a/actionpack/test/dispatch/routing_test.rb
+++ b/actionpack/test/dispatch/routing_test.rb
@@ -1443,10 +1443,10 @@ class TestRoutingMapper < ActionDispatch::IntegrationTest
def test_nested_optional_path_shorthand
with_test_routes do
get '/registrations/new'
- assert @request.params[:locale].nil?
+ assert_nil @request.params[:locale]
get '/en/registrations/new'
- assert 'en', @request.params[:locale]
+ assert_equal 'en', @request.params[:locale]
end
end