Skip to content

Commit

Permalink
Still support -append in MiniMagick
Browse files Browse the repository at this point in the history
  • Loading branch information
janko committed Jun 15, 2024
1 parent 619c791 commit 84e5b61
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
6 changes: 5 additions & 1 deletion lib/image_processing/mini_magick.rb
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,11 @@ def limits(options)

# Appends a raw ImageMagick command-line argument to the command.
def append(*args)
magick.merge! args
if args.empty?
magick.append
else
magick.merge! args
end
end

private
Expand Down
5 changes: 5 additions & 0 deletions test/mini_magick_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -597,5 +597,10 @@

assert_similar expected, actual
end

it "still supports -append" do
result = ImageProcessing::MiniMagick.append("wizard:").append.call(@portrait)
assert_dimensions [600, 1440], result
end
end
end

0 comments on commit 84e5b61

Please sign in to comment.