set ctx.l even if there's an error
@@ -116,6 +116,8 @@ for cog in bot.cog_list: # load every cog in bot.cog_list
@bot.check # everythingggg goes through here
async def global_check(ctx):
+ ctx.l = await bot.get_lang(ctx)
+
if ctx.author.id in bot.d.ban_cache:
ctx.custom_err = 'bot_banned'
return False
@@ -124,7 +126,6 @@ async def global_check(ctx):
ctx.custom_err = 'not_ready'
return False
- ctx.l = await bot.get_lang(ctx)
bot.d.cmd_lb[ctx.author.id] = bot.d.cmd_lb.get(ctx.author.id, 0) + 1
return True
