diff --git a/lib/readline-sync.js b/lib/readline-sync.js index e10db32..d4472c4 100644 --- a/lib/readline-sync.js +++ b/lib/readline-sync.js @@ -1042,7 +1042,7 @@ function getClHandler(commandHandler, options) { cmdKey = clHandler.args[0] || ''; if (!options.caseSensitive) { cmdKey = cmdKey.toLowerCase(); } clHandler.hRes = - hIndex.hasOwnProperty(cmdKey) ? + cmdKey !== '_' && hIndex.hasOwnProperty(cmdKey) ? hIndex[cmdKey].apply(res, clHandler.args.slice(1)) : hIndex.hasOwnProperty('_') ? hIndex._.apply(res, clHandler.args) : null; return {res: res, forceNext: false}; diff --git a/package.json b/package.json index 97e4fe0..4729060 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "readline-sync", - "version": "1.2.18", + "version": "1.2.19", "title": "readlineSync", "description": "Synchronous Readline for interactively running to have a conversation with the user via a console(TTY).", "keywords": [ diff --git a/screen_01.png b/screen_01.png index 1ee47d7..829eb48 100644 Binary files a/screen_01.png and b/screen_01.png differ diff --git a/screen_02.gif b/screen_02.gif index 4a49db5..9ce40ff 100644 Binary files a/screen_02.gif and b/screen_02.gif differ