diff options
Diffstat (limited to 'app/models/asset.rb')
| -rw-r--r-- | app/models/asset.rb | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/app/models/asset.rb b/app/models/asset.rb index 3ad58574..f6526f2c 100644 --- a/app/models/asset.rb +++ b/app/models/asset.rb | |||
| @@ -13,8 +13,9 @@ class Asset < ActiveRecord::Base | |||
| 13 | :headline => "460x250#" | 13 | :headline => "460x250#" |
| 14 | } | 14 | } |
| 15 | ) | 15 | ) |
| 16 | 16 | ||
| 17 | scope :images, where(:upload_content_type => ["image/gif", "image/jpeg", "image/png"]) | 17 | scope :images, -> { where(:upload_content_type => ["image/gif", "image/jpeg", "image/png"]) } |
| 18 | scope :documents, where(:upload_content_type => ["application/pdf", "text/plain", "text/rtf"]) | 18 | scope :documents, -> { where(:upload_content_type => ["application/pdf", "text/plain", "text/rtf"]) } |
| 19 | scope :audio, where(:upload_content_type => ["audio/mpeg", "audio/x-m4a", "audio/wav", "audio/x-wav"]) | 19 | scope :audio, -> { where(:upload_content_type => ["audio/mpeg", "audio/x-m4a", "audio/wav", "audio/x-wav"]) } |
| 20 | |||
| 20 | end | 21 | end |
