Fix list function in prompt
This commit is contained in:
parent
8d1919a36b
commit
b4800643e1
@ -41,12 +41,12 @@ def liste(toks, context, prompt):
|
|||||||
if l == "server" or l == "servers":
|
if l == "server" or l == "servers":
|
||||||
for srv in context.servers.keys():
|
for srv in context.servers.keys():
|
||||||
print (" - %s ;" % srv)
|
print (" - %s ;" % srv)
|
||||||
else:
|
if len(context.servers) == 0:
|
||||||
print (" > No server loaded")
|
print (" > No server loaded")
|
||||||
elif l == "mod" or l == "mods" or l == "module" or l == "modules":
|
elif l == "mod" or l == "mods" or l == "module" or l == "modules":
|
||||||
for mod in context.modules.keys():
|
for mod in context.modules.keys():
|
||||||
print (" - %s ;" % mod)
|
print (" - %s ;" % mod)
|
||||||
else:
|
if len(context.modules) == 0:
|
||||||
print (" > No module loaded")
|
print (" > No module loaded")
|
||||||
elif l in prompt.HOOKS_LIST:
|
elif l in prompt.HOOKS_LIST:
|
||||||
(f,d) = prompt.HOOKS_LIST[l]
|
(f,d) = prompt.HOOKS_LIST[l]
|
||||||
|
Loading…
Reference in New Issue
Block a user