Feature #38368 ยป webp_images_support_in_pdf_export.patch
Gemfile | ||
---|---|---|
12 | 12 |
gem 'mail', '~> 2.8.1' |
13 | 13 |
gem 'nokogiri', '~> 1.14.0' |
14 | 14 |
gem 'i18n', '~> 1.12.0' |
15 |
gem 'rbpdf', '~> 1.21.0'
|
|
15 |
gem 'rbpdf', '~> 1.21.1'
|
|
16 | 16 |
gem 'addressable' |
17 | 17 |
gem 'rubyzip', '~> 2.3.0' |
18 | 18 |
lib/redmine/export/pdf.rb | ||
---|---|---|
149 | 149 |
def self.attach(attachments, filename, encoding) |
150 | 150 |
filename_utf8 = Redmine::CodesetUtil.to_utf8(filename, encoding) |
151 | 151 |
atta = nil |
152 |
if /^[^\/"]+\.(gif|jpg|jpe|jpeg|png)$/i.match?(filename_utf8) |
|
152 |
if /^[^\/"]+\.(gif|jpg|jpe|jpeg|png|webp)$/i.match?(filename_utf8)
|
|
153 | 153 |
atta = Attachment.latest_attach(attachments, filename_utf8) |
154 | 154 |
end |
155 | 155 |
if atta && atta.readable? && atta.visible? |