diff options
author | Santiago Pastorino <santiago@wyeworks.com> | 2012-02-21 23:55:56 -0200 |
---|---|---|
committer | Santiago Pastorino <santiago@wyeworks.com> | 2012-02-22 11:13:02 -0200 |
commit | 19433ce8701d9ff2b311d0a2ec98be366ce461ea (patch) | |
tree | a2acdc41ab925c64d98b7944b3ff2d3928bb2412 /actionpack/lib/action_controller/metal/rendering.rb | |
parent | 35626feb61e260ec704ed407768da4c6a2f27a47 (diff) | |
download | rails-19433ce8701d9ff2b311d0a2ec98be366ce461ea.tar.gz rails-19433ce8701d9ff2b311d0a2ec98be366ce461ea.tar.bz2 rails-19433ce8701d9ff2b311d0a2ec98be366ce461ea.zip |
format lookup for partials is derived from the format in which the template is being rendered
Closes #5025 part 2
Diffstat (limited to 'actionpack/lib/action_controller/metal/rendering.rb')
-rw-r--r-- | actionpack/lib/action_controller/metal/rendering.rb | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_controller/metal/rendering.rb b/actionpack/lib/action_controller/metal/rendering.rb index 70fd79bb8b..02a2e3db86 100644 --- a/actionpack/lib/action_controller/metal/rendering.rb +++ b/actionpack/lib/action_controller/metal/rendering.rb @@ -14,7 +14,7 @@ module ActionController def render(*args) #:nodoc: raise ::AbstractController::DoubleRenderError if response_body super - self.content_type ||= Mime[formats.first].to_s + self.content_type ||= Mime[lookup_context.rendered_format].to_s response_body end |