From 61de526782d34c2c3540d102d8b7a9e0ac61a9ce Mon Sep 17 00:00:00 2001 From: guimoz Date: Tue, 31 Jan 2017 18:32:28 +0100 Subject: [PATCH] More debug --- roulette.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/roulette.py b/roulette.py index ba30795..63fe954 100644 --- a/roulette.py +++ b/roulette.py @@ -207,10 +207,10 @@ def ban(player_id, target_id, success): cur.execute("""update players set ban_end=%f where id=%i"""% (ban_end, banned_player['id'])) - - cur.execute("""insert into bans (player_id,target_id,success,time) - values (%i,%i,%i,%f)"""% (player['id'], target['id'], \ - success and 1 or 0, time())) + requete = """insert into bans (player_id,target_id,success,time) values (%i,%i,%i,%f)"""% (player['id'], target['id'],success and 1 or 0, time()) + cur.execute(requete) + if DEBUG: + print(requete) con.commit() con.close()