instance method
media_type
Ruby on Rails 8.1.4.1
Since v8.0.5.2 Private — implementation detail, not part of the public APISignature
media_type()
Marcel answers in canonical lowercase, so drop parameters and case before comparing.
Source
# File activestorage/app/models/active_storage/blob.rb, line 379
def media_type
content_type.to_s.split(";").first.to_s.strip.downcase
end
Defined in activestorage/app/models/active_storage/blob.rb line 379
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveStorage::Blob