mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
Fix deprecation message s/Rails 6.1 will return/Rails 7.0 will return/
`return_only_media_type_on_content_type` will be introduced in Rails 6.2 so the changing of returning Content-Type will happen in a future version of Rails (probably 7.0).
This commit is contained in:
parent
c38db72472
commit
388f602ce4
1 changed files with 2 additions and 2 deletions
|
@ -36,11 +36,11 @@ module ActionDispatch
|
|||
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
|
||||
|
|
Loading…
Reference in a new issue