From 3c4da25ec16fb53c6a34ea43a1fff6cc2c1ec4db Mon Sep 17 00:00:00 2001 From: FO-nTTaX Date: Thu, 6 Oct 2022 22:32:18 +0200 Subject: [PATCH] add missing variable prefix --- ftsbot/cogs/antispam.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ftsbot/cogs/antispam.py b/ftsbot/cogs/antispam.py index b48d3db..73ad836 100644 --- a/ftsbot/cogs/antispam.py +++ b/ftsbot/cogs/antispam.py @@ -68,7 +68,7 @@ async def on_ready(self): @commands.Cog.listener() async def on_reaction_add(self, reaction, user): # Check if user joined within last 7 days - if hasattr(message.author, 'joined_at') and (discord.utils.utcnow() - user.joined_at).days <= 7: + if hasattr(reaction.message.author, 'joined_at') and (discord.utils.utcnow() - user.joined_at).days <= 7: if user.id not in self.reactionspammers: self.reactionspammer[user.id] = 0 self.reactionspammer[user.id] += 1