Skip to content

Commit

Permalink
Merge pull request #41251 from kamipo/fix_deprecation_message
Browse files Browse the repository at this point in the history
Fix deprecation message s/Rails 6.1 will return/Rails 7.0 will return/
  • Loading branch information
rafaelfranca committed Jan 27, 2021
2 parents c38db72 + 388f602 commit 3921f24
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions actionpack/lib/action_dispatch/http/mime_negotiation.rb
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ def content_mime_type
def content_type
if self.class.return_only_media_type_on_content_type
ActiveSupport::Deprecation.warn(
"Rails 6.1 will return Content-Type header without modification." \
"Rails 7.0 will return Content-Type header without modification." \
" If you want just the MIME type, please use `#media_type` instead."
)

content_mime_type && content_mime_type.to_s
content_mime_type&.to_s
else
super
end
Expand Down

0 comments on commit 3921f24

Please sign in to comment.