diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2019-06-22 02:50:36 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-06-22 02:50:36 +0200 |
commit | aa9b37822bd39dff771844b7b1ac149e37788d34 (patch) | |
tree | 3be8da439c83958dc5076548c6042ffeff66d461 /app/models | |
parent | 84f945d64c00c73c35a3f9c23b895a4288ff2592 (diff) |
Fix audio not being downloaded from remote servers (#11145)
Diffstat (limited to 'app/models')
-rw-r--r-- | app/models/media_attachment.rb | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/app/models/media_attachment.rb b/app/models/media_attachment.rb index 4c55d4b98..a9b6d96c6 100644 --- a/app/models/media_attachment.rb +++ b/app/models/media_attachment.rb @@ -177,6 +177,14 @@ class MediaAttachment < ApplicationRecord before_save :set_meta class << self + def supported_mime_types + IMAGE_MIME_TYPES + VIDEO_MIME_TYPES + AUDIO_MIME_TYPES + end + + def supported_file_extensions + IMAGE_FILE_EXTENSIONS + VIDEO_FILE_EXTENSIONS + AUDIO_FILE_EXTENSIONS + end + private def file_styles(f) |