@trenskow/arguments-parser 0.3.88 → 0.3.89

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/lib/index.js +7 -3
  2. package/package.json +1 -1
package/lib/index.js CHANGED
@@ -248,9 +248,13 @@ const argumentsParser = (
248
248
 
249
249
  checkHelp();
250
250
 
251
- parameters[identifier] = await isvalid(
252
- args[0],
253
- schema);
251
+ try {
252
+ parameters[identifier] = await isvalid(
253
+ args[0],
254
+ schema);
255
+ } catch (error) {
256
+ printHelp(error);
257
+ }
254
258
 
255
259
  return await next(
256
260
  identifier,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@trenskow/arguments-parser",
3
- "version": "0.3.88",
3
+ "version": "0.3.89",
4
4
  "description": "Yet another arguments parser.",
5
5
  "main": "index.js",
6
6
  "type": "module",