[commands] Add Command.usage argument to override argument display.
This commit is contained in:
committed by
Rapptz
parent
bfe2b4fc03
commit
84dfd7b3e3
@@ -203,7 +203,9 @@ class HelpFormatter:
|
||||
result.append(name)
|
||||
|
||||
params = cmd.clean_params
|
||||
if len(params) > 0:
|
||||
if cmd.usage:
|
||||
result.append(cmd.usage)
|
||||
elif len(params) > 0:
|
||||
for name, param in params.items():
|
||||
if param.default is not param.empty:
|
||||
# We don't want None or '' to trigger the [name=value] case and instead it should
|
||||
|
||||
Reference in New Issue
Block a user