aboutsummaryrefslogtreecommitdiffstats
path: root/Library
diff options
context:
space:
mode:
authorJack Nagel2013-11-26 20:35:07 -0600
committerJack Nagel2013-11-26 20:35:07 -0600
commit3f573bd9ab228fe053d43fc486a8a5853b0490fc (patch)
tree7757884199e254262fc0316f389be780a2f8fa30 /Library
parent00e5ae296ed405711d82bffc37646449fc80b391 (diff)
downloadhomebrew-3f573bd9ab228fe053d43fc486a8a5853b0490fc.tar.bz2
audit: distinguish between nil and empty versions
Diffstat (limited to 'Library')
-rw-r--r--Library/Homebrew/cmd/audit.rb6
1 files changed, 4 insertions, 2 deletions
diff --git a/Library/Homebrew/cmd/audit.rb b/Library/Homebrew/cmd/audit.rb
index be8d7c077..fcb7ed22b 100644
--- a/Library/Homebrew/cmd/audit.rb
+++ b/Library/Homebrew/cmd/audit.rb
@@ -603,8 +603,10 @@ class ResourceAuditor
end
def audit_version
- if version.to_s.empty?
- problem "invalid or missing version"
+ if version.nil?
+ problem "missing version"
+ elsif version.to_s.empty?
+ problem "version is set to an empty string"
elsif not version.detected_from_url?
version_text = version
version_url = Version.detect(url, specs)