From e2741819830dc2afe4ad63810d468240ab1a2adb Mon Sep 17 00:00:00 2001 From: schneefux Date: Sat, 28 May 2016 20:53:34 +0200 Subject: fix form submits not working on pages --- app.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'app.py') diff --git a/app.py b/app.py index 78c97f2..51059d1 100644 --- a/app.py +++ b/app.py @@ -50,13 +50,13 @@ class dbProxy(object): def voteJoke(self, objectId, down): if down: - self.c.execute("UPDATE jokes SET downvotes=downvotes+1 WHERE id=?", (objectId)) + self.c.execute("UPDATE jokes SET downvotes=downvotes+1 WHERE id=?", (objectId,)) else: - self.c.execute("UPDATE jokes SET upvotes=upvotes+1 WHERE id=?", (objectId)) + self.c.execute("UPDATE jokes SET upvotes=upvotes+1 WHERE id=?", (objectId,)) self.conn.commit() def reportJoke(self, objectId): - self.c.execute("UPDATE jokes SET reports=reports+1 WHERE id=?", (objectId)) + self.c.execute("UPDATE jokes SET reports=reports+1 WHERE id=?", (objectId,)) self.conn.commit() -- cgit v1.3.1