Skip to content

Commit b907ff6

Browse files
author
MuffinMedic
committed
Sort cmdinfo and potential match help outputs
1 parent 74c9c76 commit b907ff6

2 files changed

Lines changed: 2 additions & 2 deletions

File tree

cloudbot/bot.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,7 @@ def add_hook(hook, _event, _run_before=False):
314314
add_hook(command_hook, command_event)
315315
else:
316316
event.notice("Possible matches: {}".format(
317-
formatting.get_text_list([command for command, plugin in potential_matches])))
317+
formatting.get_text_list(sorted([command for command, plugin in potential_matches]))))
318318

319319
if event.type in (EventType.message, EventType.action):
320320
# Regex hooks

plugins/core/help.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ def cmdinfo(text, bot, notice):
9292
cmd_hook = potentials[0][1]
9393
else:
9494
notice("Possible matches: {}".format(
95-
formatting.get_text_list([command for command, plugin in potentials])))
95+
formatting.get_text_list(sorted([command for command, plugin in potentials]))))
9696
return
9797
else:
9898
cmd_hook = None

0 commit comments

Comments
 (0)