aboutsummaryrefslogtreecommitdiffstats
path: root/actionview/lib/action_view/rendering.rb
diff options
context:
space:
mode:
authorŁukasz Strzałkowski <lukasz.strzalkowski@gmail.com>2013-07-23 18:50:22 +0200
committerŁukasz Strzałkowski <lukasz.strzalkowski@gmail.com>2013-08-25 11:39:11 +0200
commitcb2d671cb884a7cfeb991ce5af5d7e1047685dbd (patch)
tree90aec1f8fe301c87f240ce36660a41faeb5c38bf /actionview/lib/action_view/rendering.rb
parent0b4507a26f7c4807ea14ce70c41033c9868f83e3 (diff)
downloadrails-cb2d671cb884a7cfeb991ce5af5d7e1047685dbd.tar.gz
rails-cb2d671cb884a7cfeb991ce5af5d7e1047685dbd.tar.bz2
rails-cb2d671cb884a7cfeb991ce5af5d7e1047685dbd.zip
Move setting content_type to AV
Diffstat (limited to 'actionview/lib/action_view/rendering.rb')
-rw-r--r--actionview/lib/action_view/rendering.rb2
1 files changed, 2 insertions, 0 deletions
diff --git a/actionview/lib/action_view/rendering.rb b/actionview/lib/action_view/rendering.rb
index e3d0beade3..0db469766c 100644
--- a/actionview/lib/action_view/rendering.rb
+++ b/actionview/lib/action_view/rendering.rb
@@ -82,6 +82,8 @@ module ActionView
super(*args, &block)
options = _normalize_render(*args, &block)
+
+ self.content_type ||= Mime[lookup_context.rendered_format].to_s
self.response_body = render_to_body(options)
end