From 8c47eef18f1c81e57a80d16c723bee7d2a59ee8f Mon Sep 17 00:00:00 2001 From: Timo Hocker Date: Wed, 4 Mar 2020 11:49:35 +0100 Subject: [PATCH] fix 'no minus in node name' --- snippets/node/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/snippets/node/index.js b/snippets/node/index.js index 882873e..9dfacda 100644 --- a/snippets/node/index.js +++ b/snippets/node/index.js @@ -88,8 +88,8 @@ function assert (folder, args) { reason: 'name is not a string' }, { - f: () => (args.length === 0 || (/^[a-z]+$/iu).test (args[0])), - reason: 'name can only contain [a-z]' + f: () => (args.length === 0 || (/^[a-z-]+$/iu).test (args[0])), + reason: 'name can only contain [a-z-]' }, { f: () => (typeof folder === 'string'),