aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/lib/action_dispatch/middleware/params_parser.rb
diff options
context:
space:
mode:
Diffstat (limited to 'actionpack/lib/action_dispatch/middleware/params_parser.rb')
-rw-r--r--actionpack/lib/action_dispatch/middleware/params_parser.rb6
1 files changed, 4 insertions, 2 deletions
diff --git a/actionpack/lib/action_dispatch/middleware/params_parser.rb b/actionpack/lib/action_dispatch/middleware/params_parser.rb
index f4c4324fb0..18a3688bb0 100644
--- a/actionpack/lib/action_dispatch/middleware/params_parser.rb
+++ b/actionpack/lib/action_dispatch/middleware/params_parser.rb
@@ -25,7 +25,9 @@ module ActionDispatch
return false if request.content_length.zero?
- mime_type = content_type_from_legacy_post_data_format_header(env) || request.content_type
+ mime_type = content_type_from_legacy_post_data_format_header(env) ||
+ request.content_mime_type
+
strategy = @parsers[mime_type]
return false unless strategy
@@ -53,7 +55,7 @@ module ActionDispatch
raise
{ "body" => request.raw_post,
- "content_type" => request.content_type,
+ "content_type" => request.content_mime_type,
"content_length" => request.content_length,
"exception" => "#{e.message} (#{e.class})",
"backtrace" => e.backtrace }