From 4eebf4ef2ffdd8b79bfc8322a13c49dc5ee64564 Mon Sep 17 00:00:00 2001 From: Phxntxm Date: Fri, 15 Jul 2016 14:22:04 -0500 Subject: [PATCH] Fixed syntax error --- cogs/mod.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/cogs/mod.py b/cogs/mod.py index c4c4caa..9c9bfad 100644 --- a/cogs/mod.py +++ b/cogs/mod.py @@ -83,14 +83,14 @@ class Mod: if result is None: await self.bot.say("There are no custom permissions setup on this server yet!") return - - cursor.execute('select perms from custom_permissions where server_id=%s and command=%s', (ctx.message.server.id,command)) + sql = "select perms from `"+ctx.message.server.id+"` where command=%s" + cursor.execute(sql, (command,)) result = cursor.fetchone() if result is None: await self.bot.say("That command has no custom permissions setup on it!") return - await self.bot.say("You need to have the permission `{}` to use the command `{}` in this server".format(result['perm'],command)) + await self.bot.say("You need to have the permission `{}` to use the command `{}` in this server".format(result['perms'],command)) @perms.command(name="add", aliases=["setup,create"], pass_context=True) @commands.has_permissions(manage_server=True)