diff options
| author | 2021-10-25 21:58:36 +0200 | |
|---|---|---|
| committer | 2021-10-25 20:20:03 +0000 | |
| commit | d957e2d9158e2fb0e43de33c8b174b759da4d905 (patch) | |
| tree | 510641a01ba2013dbb00dfd9d71ac4754aa33900 | |
| parent | Fltering: clean up autoban code (diff) | |
Filtering: fix ban flow
| -rw-r--r-- | bot/exts/filters/filtering.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/bot/exts/filters/filtering.py b/bot/exts/filters/filtering.py index 5e91e7e3d..30b447620 100644 --- a/bot/exts/filters/filtering.py +++ b/bot/exts/filters/filtering.py @@ -369,11 +369,12 @@ class Filtering(Cog): # We create a new context from that message and make sure the staffer is the bot # and the feedback message is sent in #mod-alert context = await self.bot.get_context(msg) - context.author = self.bot.user + context.author = self.bot.get_guild(Guild.id).get_member(self.bot.user.id) context.channel = self.bot.get_channel(Channels.mod_alerts) + context.command = self.bot.get_command("tempban") await context.invoke( - self.bot.get_command("tempban"), + context.command, msg.author, arrow.utcnow() + AUTO_BAN_DURATION, reason=AUTO_BAN_REASON |