aboutsummaryrefslogtreecommitdiffstats
path: root/Library/Homebrew/cmd/command.rb
diff options
context:
space:
mode:
Diffstat (limited to 'Library/Homebrew/cmd/command.rb')
-rw-r--r--Library/Homebrew/cmd/command.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/Library/Homebrew/cmd/command.rb b/Library/Homebrew/cmd/command.rb
index c2ea96dab..6dce00e32 100644
--- a/Library/Homebrew/cmd/command.rb
+++ b/Library/Homebrew/cmd/command.rb
@@ -3,7 +3,7 @@ module Homebrew
cmd = ARGV.first
cmd = HOMEBREW_INTERNAL_COMMAND_ALIASES.fetch(cmd, cmd)
- if (path = HOMEBREW_LIBRARY_PATH/"cmd/#{cmd}.rb"; path.file?)
+ if (path = HOMEBREW_LIBRARY_PATH/"cmd/#{cmd}.rb" && path.file?)
puts path
elsif (path = which("brew-#{cmd}") || which("brew-#{cmd}.rb"))
puts path