only get counts if needed

This commit is contained in:
Adam Vandenberg 2014-02-23 22:07:30 -08:00
parent f5cc07dfea
commit c189dd6e20

View File

@ -38,11 +38,10 @@ module Homebrew extend self
repair_taps unless ARGV.dry_run?
n, d = ObserverPathnameExtension.counts
if ObserverPathnameExtension.total.zero?
puts "Nothing pruned" if ARGV.verbose?
else
n, d = ObserverPathnameExtension.counts
print "Pruned #{n} symbolic links "
print "and #{d} directories " if d > 0
puts "from #{HOMEBREW_PREFIX}"