From d33462dd09f21d7406f96b404fce8ebe0ae277d0 Mon Sep 17 00:00:00 2001 From: Conatum Date: Thu, 20 Jan 2022 13:40:33 +0200 Subject: [PATCH] (topgg): Add ignores to reply hook. --- bot/modules/topgg/module.py | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/bot/modules/topgg/module.py b/bot/modules/topgg/module.py index 8c8e9ff9..a6e6857e 100644 --- a/bot/modules/topgg/module.py +++ b/bot/modules/topgg/module.py @@ -33,7 +33,15 @@ async def unregister_hook(client): async def topgg_reply_wrapper(func, *args, suggest_vote=True, **kwargs): - if suggest_vote and not get_last_voted_timestamp(args[0].author.id): + ctx = args[0] + + if not suggest_vote: + pass + elif ctx.cmd and ctx.cmd.name == 'config': + pass + elif ctx.cmd and ctx.cmd.name == 'help' and ctx.args and ctx.args.split(maxsplit=1)[0].lower() == 'vote': + pass + elif not get_last_voted_timestamp(args[0].author.id): upvote_info_formatted = upvote_info.format(lion_yayemote, args[0].best_prefix, lion_loveemote) if 'embed' in kwargs: