Skip to content

Commit 31b0236

Browse files
committed
removed keyless options from help
1 parent 8eb22d5 commit 31b0236

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

lib/server.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,8 @@ function buildHelp(defaultServer) {
8787
opts = opts.concat(method.options);
8888
}
8989
opts.forEach(function eachOptions(option) {
90+
var nokey = method.nokey && method.nokey.indexOf(option) > -1;
91+
9092
Object.keys(option).forEach(function eachOption(optKey) {
9193
var opt = option[optKey];
9294

@@ -96,8 +98,7 @@ function buildHelp(defaultServer) {
9698
}
9799

98100
options[[
99-
opt.key,
100-
', ',
101+
opt.key && !nokey ? opt.key + ', ' : '',
101102
optKey
102103
].join('')] = optKey === 'server' ?
103104
opt.info.replace('%s', defaultServer) : opt.info;

0 commit comments

Comments
 (0)