Permalink
Browse files

CLI Tool - Call fail on no valid versions

Return status code 1 even when no valid versions are passed.
  • Loading branch information...
1 parent 16197e3 commit fc75b1f5b8d6ddbd8f38efef502d8c739bac3c3e @mal mal committed with isaacs Nov 28, 2012
Showing with 1 addition and 0 deletions.
  1. +1 −0 bin/semver
View
@@ -33,6 +33,7 @@ function main () {
}
versions = versions.filter(semver.valid)
+ if (!versions.length) return fail()
for (var i = 0, l = range.length; i < l ; i ++) {
versions = versions.filter(function (v) {
return semver.satisfies(v, range[i])

0 comments on commit fc75b1f

Please sign in to comment.