Show correct message when invalid arguments are passed to brew
This commit is contained in:
parent
44eada21d5
commit
aed6bc194d
@ -221,9 +221,14 @@ module Cask
|
|||||||
usage
|
usage
|
||||||
|
|
||||||
return if @command.nil?
|
return if @command.nil?
|
||||||
return if @command == "help" && @args.empty?
|
|
||||||
|
|
||||||
raise ArgumentError, "help does not take arguments."
|
if @command == "help"
|
||||||
|
return if @args.empty?
|
||||||
|
|
||||||
|
raise ArgumentError, "help does not take arguments." if @args.length
|
||||||
|
end
|
||||||
|
|
||||||
|
raise ArgumentError, "brew cask does not recognise this command"
|
||||||
end
|
end
|
||||||
|
|
||||||
def purpose
|
def purpose
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user