diff options
author | José Valim <jose.valim@gmail.com> | 2010-01-20 14:21:27 +0100 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2010-01-20 15:02:13 +0100 |
commit | 8e2fd54b19656a6edbd94f8707927d09e167e7fc (patch) | |
tree | c000b4aa817f677d8160a13e630a2536e76264d0 /actionpack/lib/action_controller/metal/rendering.rb | |
parent | 8b9bfbe225a59ccefa46f1e8bf301bc483bef0e0 (diff) | |
download | rails-8e2fd54b19656a6edbd94f8707927d09e167e7fc.tar.gz rails-8e2fd54b19656a6edbd94f8707927d09e167e7fc.tar.bz2 rails-8e2fd54b19656a6edbd94f8707927d09e167e7fc.zip |
Bring normalize behavior to AbstractController::Rendering
Diffstat (limited to 'actionpack/lib/action_controller/metal/rendering.rb')
-rw-r--r-- | actionpack/lib/action_controller/metal/rendering.rb | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/actionpack/lib/action_controller/metal/rendering.rb b/actionpack/lib/action_controller/metal/rendering.rb index 74e50bb032..475ed54167 100644 --- a/actionpack/lib/action_controller/metal/rendering.rb +++ b/actionpack/lib/action_controller/metal/rendering.rb @@ -12,9 +12,10 @@ module ActionController super end - def render(options) - super - self.content_type ||= options[:_template].mime_type.to_s + def render(*args) + args << {} unless args.last.is_a?(Hash) + super(*args) + self.content_type ||= args.last[:_template].mime_type.to_s response_body end |