1
0
Fork 0
mirror of synced 2024-05-19 20:12:30 +12:00

Corrected the MySQL search around the URL that, by adding quotes

This commit is contained in:
Phxntxm 2016-07-10 10:59:30 -05:00
parent 9355c2af81
commit 5da878ee29

View file

@ -46,7 +46,7 @@ class Twitch:
cursor.execute('select twitch_url from twitch where user_id="{}"'.format(ctx.message.author.id))
result = cursor.fetchone()
if result is not None:
cursor.execute('update twitch set twitch_url={} from twitch where user_id="{}"'.format(url,ctx.message.author.id))
cursor.execute('update twitch set twitch_url="{}" from twitch where user_id="{}"'.format(url,ctx.message.author.id))
else:
cursor.execute('insert into twitch (user_id,server_id,twitch_url,notifications_on) values ("{}","{}","{}",1)'
.format(ctx.message.author.id,ctx.message.server.id,url))