From 43c7bd48c74019c8c01dd727d256d05ebaed333e Mon Sep 17 00:00:00 2001 From: El Laggron Date: Thu, 12 Jul 2018 02:54:32 +0100 Subject: [PATCH] [V3 Mod] Fix wrong reason used for modlog (#1842) --- redbot/cogs/mod/mod.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/redbot/cogs/mod/mod.py b/redbot/cogs/mod/mod.py index c1e72f5e1..2694aff4d 100644 --- a/redbot/cogs/mod/mod.py +++ b/redbot/cogs/mod/mod.py @@ -645,7 +645,7 @@ class Mod: if not user: await ctx.send(_("Couldn't find a user with that ID!")) return - reason = get_audit_reason(ctx.author, reason) + audit_reason = get_audit_reason(ctx.author, reason) bans = await guild.bans() bans = [be.user for be in bans] if user not in bans: @@ -654,7 +654,7 @@ class Mod: queue_entry = (guild.id, user.id) self.unban_queue.append(queue_entry) try: - await guild.unban(user, reason=reason) + await guild.unban(user, reason=audit_reason) except discord.HTTPException: self.unban_queue.remove(queue_entry) await ctx.send(_("Something went wrong while attempting to unban that user"))