diff options
author | Aaron Patterson <aaron.patterson@gmail.com> | 2015-09-15 07:43:04 -0700 |
---|---|---|
committer | Aaron Patterson <aaron.patterson@gmail.com> | 2015-09-15 07:43:04 -0700 |
commit | 49316d8a6357bbb19c2032faa3dfec8f7e0f0253 (patch) | |
tree | 50496c92742e83a969183bb61146fe61d9773f9f /actionpack | |
parent | ec6638a23756ea104f203546df15a5e3e0dff229 (diff) | |
download | rails-49316d8a6357bbb19c2032faa3dfec8f7e0f0253.tar.gz rails-49316d8a6357bbb19c2032faa3dfec8f7e0f0253.tar.bz2 rails-49316d8a6357bbb19c2032faa3dfec8f7e0f0253.zip |
fewer direct env manipulations
this commit removes some direct access to `env`.
Diffstat (limited to 'actionpack')
-rw-r--r-- | actionpack/lib/action_controller/metal/request_forgery_protection.rb | 2 | ||||
-rw-r--r-- | actionpack/lib/action_dispatch/http/request.rb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/actionpack/lib/action_controller/metal/request_forgery_protection.rb b/actionpack/lib/action_controller/metal/request_forgery_protection.rb index e5f3cb8e8d..2ddf34f40f 100644 --- a/actionpack/lib/action_controller/metal/request_forgery_protection.rb +++ b/actionpack/lib/action_controller/metal/request_forgery_protection.rb @@ -137,7 +137,7 @@ module ActionController #:nodoc: def handle_unverified_request request = @controller.request request.session = NullSessionHash.new(request) - request.env['action_dispatch.request.flash_hash'] = nil + request.flash = nil request.env['rack.session.options'] = { skip: true } request.cookie_jar = NullCookieJar.build(request, {}) end diff --git a/actionpack/lib/action_dispatch/http/request.rb b/actionpack/lib/action_dispatch/http/request.rb index 18504eba6d..b2566c4820 100644 --- a/actionpack/lib/action_dispatch/http/request.rb +++ b/actionpack/lib/action_dispatch/http/request.rb @@ -324,7 +324,7 @@ module ActionDispatch else self.session = {} end - set_header('action_dispatch.request.flash_hash', nil) + self.flash = nil end def session=(session) #:nodoc: |