]> source.dussan.org Git - redmine.git/commitdiff
Update MiniMagick to 5.0 (#41312).
authorGo MAEDA <maeda@farend.jp>
Wed, 2 Oct 2024 23:46:17 +0000 (23:46 +0000)
committerGo MAEDA <maeda@farend.jp>
Wed, 2 Oct 2024 23:46:17 +0000 (23:46 +0000)
Patch by Katsuya HIDAKA (user:hidakatsuya).

git-svn-id: https://svn.redmine.org/redmine/trunk@23099 e93f8b46-1217-0410-a6f0-8f06a7374b81

Gemfile
lib/redmine/helpers/gantt.rb

diff --git a/Gemfile b/Gemfile
index 544aa16f00676bc51fe375293b4e8d38c7478ec5..46eeb92760067517cdd74910f91612284cd88509 100644 (file)
--- a/Gemfile
+++ b/Gemfile
@@ -41,7 +41,7 @@ end
 
 # Optional gem for exporting the gantt to a PNG file
 group :minimagick do
-  gem 'mini_magick', '~> 4.13.0'
+  gem 'mini_magick', '~> 5.0.1'
 end
 
 # Optional Markdown support
index a365dccb8aff91867196f885222920c35f386856..0b5c1b1f12d49870d1fb263ad8c5370f4de686cf 100644 (file)
@@ -394,11 +394,11 @@ module Redmine
         font_path =
           Redmine::Configuration['minimagick_font_path'].presence ||
             Redmine::Configuration['rmagick_font_path'].presence
-        img = MiniMagick::Image.create(".#{format}", false)
+        img = MiniMagick::Image.create(".#{format}")
         if Redmine::Configuration['imagemagick_convert_command'].present?
           MiniMagick.cli_path = File.dirname(Redmine::Configuration['imagemagick_convert_command'])
         end
-        MiniMagick::Tool::Convert.new do |gc|
+        MiniMagick.convert do |gc|
           gc.size('%dx%d' % [subject_width + g_width + 1, height])
           gc.xc('white')
           gc.font(font_path) if font_path.present?