Class: Cdx::Asset
- Inherits:
-
ApplicationRecord
- Object
- ActiveRecord::Base
- ApplicationRecord
- Cdx::Asset
- Defined in:
- app/models/cdx/asset.rb
Constant Summary collapse
- IMAGE_CONTENT_TYPE =
%w(image/jpeg image/jpg image/png image/gif).freeze
Instance Method Summary collapse
Methods included from AttachmentMacros
#has_many_attached, #has_one_attached
Instance Method Details
#image? ⇒ Boolean
7 8 9 |
# File 'app/models/cdx/asset.rb', line 7 def image? IMAGE_CONTENT_TYPE.include? end |