Skip to Content Skip to Search

module ActiveStorage::Blob::Identifiable

Active Storage Blob Identifiable

Public instance methods

identified?()

Permalink
Source code GitHub
# File activestorage/app/models/active_storage/blob/identifiable.rb, line 17
def identified?
  identified
end

identify()

Permalink
Source code GitHub
# File activestorage/app/models/active_storage/blob/identifiable.rb, line 5
def identify
  identify_without_saving
  save!
end

identify_without_saving()

Permalink
Source code GitHub
# File activestorage/app/models/active_storage/blob/identifiable.rb, line 10
def identify_without_saving
  unless identified?
    self.content_type = identify_content_type
    self.identified = true
  end
end

Definition files