about summary refs log tree commit diff
path: root/app/models
diff options
context:
space:
mode:
authorEugen Rochko <eugen@zeonfederated.com>2019-06-21 22:59:44 +0200
committermultiple creatures <dev@multiple-creature.party>2020-02-21 03:42:29 -0600
commit9e534aad191af5209e2f08183cad6b25cba34a93 (patch)
tree2f4e8bdbc6b3b03c5c7a952e00a1bc44a6d86cb8 /app/models
parent2dacf79bcc58094b58f1689189ce130fb34b2c8f (diff)
Change audio format from ogg to mp3 for wider compatibility (#11141)
* Change audio format from ogg to mp3 for wider compatibility

* Add media description as title to links of unknown media attachments
Diffstat (limited to 'app/models')
-rw-r--r--app/models/media_attachment.rb10
1 files changed, 7 insertions, 3 deletions
diff --git a/app/models/media_attachment.rb b/app/models/media_attachment.rb
index ce3549539..e2a44d457 100644
--- a/app/models/media_attachment.rb
+++ b/app/models/media_attachment.rb
@@ -86,9 +86,13 @@ class MediaAttachment < ApplicationRecord
 
   AUDIO_STYLES = {
     original: {
-      format: 'ogg',
-      content_type: 'audio/ogg',
-      convert_options: {},
+      format: 'mp3',
+      content_type: 'audio/mpeg',
+      convert_options: {
+        output: {
+          'q:a' => 2,
+        },
+      },
     },
   }.freeze