FIX: use 'jpg' instead of 'jpe' extension for 'image/jpeg' content type

This commit is contained in:
Régis Hanol 2017-06-22 12:53:56 +02:00
parent e50bd38013
commit ca539854c8

View File

@ -31,6 +31,7 @@ class FileHelper
if extension.blank? && downloaded.content_type.present?
ext = MiniMime.lookup_by_content_type(downloaded.content_type)&.extension
ext = "jpg" if ext == "jpe"
extension = "." + ext if ext.present?
end