Skip to content

Commit

Permalink
Suppress warning: method redefined; discarding old cli and cli=
Browse files Browse the repository at this point in the history
  • Loading branch information
koic committed May 26, 2019
1 parent ff8f5df commit 2965e55
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions lib/mini_magick/configuration.rb
Original file line number Diff line number Diff line change
Expand Up @@ -135,11 +135,21 @@ def processor=(processor)
end
end

##
# Get [ImageMagick](http://www.imagemagick.org) or
# [GraphicsMagick](http://www.graphicsmagick.org).
#
# @return [Symbol] `:imagemagick` or `:graphicsmagick`
#
def cli
@cli || CLI_DETECTION.key(processor) or
fail MiniMagick::Error, "You must have ImageMagick or GraphicsMagick installed"
end

##
# Set whether you want to use [ImageMagick](http://www.imagemagick.org) or
# [GraphicsMagick](http://www.graphicsmagick.org).
#
def cli=(value)
@cli = value

Expand Down

0 comments on commit 2965e55

Please sign in to comment.