Feature #33902 ยป inline_attachment_images.patch
| inline_attachment_images.rb 2020-08-25 08:46:12.000000000 +0200 | ||
|---|---|---|
|
def disposition(attachment)
|
||
|
module InlineAttachmentImages
|
||
|
private def disposition(attachment)
|
||
|
if attachment.is_pdf?
|
||
|
'inline'
|
||
|
elsif attachment.is_image?
|
||
|
'inline'
|
||
|
else
|
||
|
'attachment'
|
||
|
end
|
||
|
end
|
||
|
end
|
||
|
require_dependency 'attachments_controller'
|
||
|
class ::AttachmentsController
|
||
|
prepend InlineAttachmentImages
|
||
|
end
|
||