method

format

Importance_0
Ruby on Rails latest stable (v7.1.3.2) - 0 notes - Class: Representable
format() private

No documentation

This method has no description. You can help the Ruby on Rails community by adding new notes.

Hide source
# File activestorage/app/models/active_storage/blob/representable.rb, line 118
    def format
      if filename.extension.present? && Marcel::MimeType.for(extension: filename.extension) == content_type
        filename.extension
      else
        Marcel::Magic.new(content_type.to_s).extensions.first
      end
    end
Register or log in to add new notes.