use `fetch` on ALIASES with default

This commit is contained in:
Roland Walker 2014-06-20 14:02:13 -04:00
parent 5005ad67f9
commit 7956854e41
1 changed files with 1 additions and 1 deletions

View File

@ -48,7 +48,7 @@ class Cask::CLI
end
def self.lookup_command(command_string)
command_string = ALIASES[command_string] if ALIASES.key?(command_string)
command_string = ALIASES.fetch(command_string, command_string)
if command_string && Cask::CLI.const_defined?(command_string.capitalize)
Cask::CLI.const_get(command_string.capitalize)
else