Skip to content

Commit

Permalink
check bug fixed plus a handy string
Browse files Browse the repository at this point in the history
  • Loading branch information
James Halliday committed Nov 7, 2010
1 parent 32853b8 commit a4843a9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/optimist.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,9 @@ function Argv (args, cwd) {

self.check = function (f) {
try {
if (f(self.argv) === false) fail(err);
if (f(self.argv) === false) fail(
'Argument check failed: ' + f.toString()
);
}
catch (err) { fail(err) }

Expand Down

0 comments on commit a4843a9

Please sign in to comment.