From f2b5eb853273e032393a858ea2b15a090aad07ab Mon Sep 17 00:00:00 2001 From: Romain Beaumont Date: Sun, 10 Jan 2016 19:58:22 +0100 Subject: [PATCH] show help if there is not exactly one argument for info, create, download, add and seed, fix #567 --- bin/cmd.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/bin/cmd.js b/bin/cmd.js index f427567d..660a9945 100755 --- a/bin/cmd.js +++ b/bin/cmd.js @@ -133,7 +133,9 @@ playerName = argv.airplay ? 'Airplay' var command = argv._[0] -if (command === 'help' || argv.help) { +if (['info', 'create', 'download', 'add', 'seed'].indexOf(command) !== -1 && argv._.length !== 2) { + runHelp() +} else if (command === 'help' || argv.help) { runHelp() } else if (command === 'version' || argv.version) { runVersion()