Remove an erroneous level of indentation that prevented the command being

prepended to a usage string when only 1 usage string was available (commands.py)
This commit is contained in:
jesopo 2018-12-29 21:35:06 +00:00
parent e8b69b0a26
commit ee8d3a6287

View file

@ -251,9 +251,10 @@ class Module(ModuleManager.BaseModule):
usage = hook.get_kwarg("usage", None)
if not usage:
usages = hook.docstring.var_items.get("usage", None)
if usages:
return " | ".join(
"%s %s" % (command, usage) for usage in usages)
if usages:
return " | ".join(
"%s %s" % (command, usage) for usage in usages)
return usage
def _get_prefix(self, hook):