diff options
author | wycats <wycats@gmail.com> | 2010-06-02 22:56:41 +0200 |
---|---|---|
committer | Mikel Lindsaar <raasdnil@gmail.com> | 2010-06-03 23:32:12 +1000 |
commit | e57dbfe6af368cca9f4c827eb70937086cbf7ed7 (patch) | |
tree | 8b9d057a91861756260aea7990308975305ab475 /actionpack/lib/action_controller/metal/rack_delegation.rb | |
parent | a9753637f4fcb68f65da96c85dfcb74ca1c13184 (diff) | |
download | rails-e57dbfe6af368cca9f4c827eb70937086cbf7ed7.tar.gz rails-e57dbfe6af368cca9f4c827eb70937086cbf7ed7.tar.bz2 rails-e57dbfe6af368cca9f4c827eb70937086cbf7ed7.zip |
Changes made while working on upgrading cells to Rails 3
Diffstat (limited to 'actionpack/lib/action_controller/metal/rack_delegation.rb')
-rw-r--r-- | actionpack/lib/action_controller/metal/rack_delegation.rb | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/actionpack/lib/action_controller/metal/rack_delegation.rb b/actionpack/lib/action_controller/metal/rack_delegation.rb index 060117756e..508ea6e2b7 100644 --- a/actionpack/lib/action_controller/metal/rack_delegation.rb +++ b/actionpack/lib/action_controller/metal/rack_delegation.rb @@ -8,10 +8,10 @@ module ActionController delegate :headers, :status=, :location=, :content_type=, :status, :location, :content_type, :to => "@_response" - def dispatch(action, request) - @_response = ActionDispatch::Response.new - @_response.request = request - super + def dispatch(action, request, response = ActionDispatch::Response.new) + @_response ||= response + @_response.request ||= request + super(action, request) end def params |