Open scotthovestadt opened 8 years ago
I recently updated it (like 2 days ago) so you can just return true
, or false
, or a message.
https://github.com/dthree/vorpal/wiki/api-|-vorpal.command#commandvalidatefunction
I agree with async as an option, sorry, I just hadn't gotten to it. :+1: on implementing.
What's the status of this one? Still interested? I'd also like async validation.
Validation shouldn't need to throw an error. It doesn't fit with the way the rest of the code works. It should be allowed to return a promise or act on a callback like everything else does.
I need async validation.
@dthree Any concerns?