From fe4eaeb182553f81afc7451c4aeaf1d865a9b18c Mon Sep 17 00:00:00 2001 From: ks129 <45097959+ks129@users.noreply.github.com> Date: Mon, 28 Sep 2020 15:36:02 +0300 Subject: Help: Show different message for case when command is disabled --- bot/exts/info/help.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/bot/exts/info/help.py b/bot/exts/info/help.py index 5d83f8f86..803fcb2bb 100644 --- a/bot/exts/info/help.py +++ b/bot/exts/info/help.py @@ -173,8 +173,11 @@ class CustomHelpCommand(HelpCommand): if aliases: command_details += f"**Can also use:** {aliases}\n\n" - # check if the user is allowed to run this command - if not command.enabled or not await command.can_run(self.context): + # when command is disabled, show message about it + # otherwise check if the user is allowed to run this command + if not command.enabled: + command_details += "***This command is disabled.***\n\n" + elif not await command.can_run(self.context): command_details += "***You cannot run this command.***\n\n" command_details += f"*{command.help or 'No details provided.'}*\n" -- cgit v1.2.3