From 195b89d33619e0ce4271cef33fc29379254206f1 Mon Sep 17 00:00:00 2001 From: Michael Stanclift Date: Wed, 3 Jan 2024 13:02:53 -0600 Subject: [PATCH] Fix .opus file uploads being misidentified by Paperclip (#28580) --- app/models/concerns/attachmentable.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/models/concerns/attachmentable.rb b/app/models/concerns/attachmentable.rb index 4cdbdeb4738..3b7db1fcef3 100644 --- a/app/models/concerns/attachmentable.rb +++ b/app/models/concerns/attachmentable.rb @@ -11,11 +11,12 @@ module Attachmentable # For some file extensions, there exist different content # type variants, and browsers often send the wrong one, # for example, sending an audio .ogg file as video/ogg, - # likewise, MimeMagic also misreports them as such. For + # likewise, kt-paperclip also misreports them as such. For # those files, it is necessary to use the output of the # `file` utility instead INCORRECT_CONTENT_TYPES = %w( audio/vorbis + audio/opus video/ogg video/webm ).freeze