Changed error handling for removing a tag, to print the tag that is failing
This commit is contained in:
parent
ae6692867a
commit
61defbc824
|
@ -197,7 +197,7 @@ class Core:
|
||||||
cursor.execute('select * from tags where server_id=%s and tag=%s', (ctx.message.server.id, tag))
|
cursor.execute('select * from tags where server_id=%s and tag=%s', (ctx.message.server.id, tag))
|
||||||
result = cursor.fetchone()
|
result = cursor.fetchone()
|
||||||
if result is None:
|
if result is None:
|
||||||
await self.bot.say("That tag does not exist! You can't remove something if it doesn't exist...")
|
await self.bot.say("The tag {} does not exist! You can't remove something if it doesn't exist...".format(tag))
|
||||||
config.closeConnection()
|
config.closeConnection()
|
||||||
return
|
return
|
||||||
cursor.execute('delete from tags where server_id=%s and tag=%s', (ctx.message.server.id, tag))
|
cursor.execute('delete from tags where server_id=%s and tag=%s', (ctx.message.server.id, tag))
|
||||||
|
|
Loading…
Reference in a new issue