aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack
diff options
context:
space:
mode:
authorAaron Patterson <aaron.patterson@gmail.com>2015-08-26 10:34:36 -0700
committerAaron Patterson <aaron.patterson@gmail.com>2015-08-26 10:51:13 -0700
commit27daea82d77a81a866ca20f547ab66e0f47d6380 (patch)
treeb41febb5ec2576fd92f23ed950d3cc23de90da3f /actionpack
parent02f5a28f4093173eafb6e2e6b82feb7e04d94d1b (diff)
downloadrails-27daea82d77a81a866ca20f547ab66e0f47d6380.tar.gz
rails-27daea82d77a81a866ca20f547ab66e0f47d6380.tar.bz2
rails-27daea82d77a81a866ca20f547ab66e0f47d6380.zip
use the content_type method on the request object
since the controller always has a request on it, we can just ask the request for the content type.
Diffstat (limited to 'actionpack')
-rw-r--r--actionpack/lib/action_controller/metal.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/actionpack/lib/action_controller/metal.rb b/actionpack/lib/action_controller/metal.rb
index 4eff607782..85eba195ce 100644
--- a/actionpack/lib/action_controller/metal.rb
+++ b/actionpack/lib/action_controller/metal.rb
@@ -176,7 +176,7 @@ module ActionController
end
def content_type
- headers["Content-Type"]
+ request.content_type
end
def location