From 2211e8568e84ff4b0ea87de12f191c22fef64ed1 Mon Sep 17 00:00:00 2001 From: Joscha Date: Fri, 3 Aug 2018 18:15:38 +0000 Subject: [PATCH] Adapt to yaboli changes --- plusone.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/plusone.py b/plusone.py index 0a1c34c..1d46ff9 100644 --- a/plusone.py +++ b/plusone.py @@ -24,8 +24,8 @@ class PointDB(yaboli.Database): db.commit() @yaboli.operation - def add_point(db, nick): - nick = mention_reduced(nick) + def add_point(self, db, nick): + nick = normalize(nick) cur = db.cursor() cur.execute("INSERT OR IGNORE INTO Points (nick, points) VALUES (?, 0)", (nick,)) @@ -33,8 +33,8 @@ class PointDB(yaboli.Database): db.commit() @yaboli.operation - def points_of(db, nick): - nick = mention_reduced(nick) + def points_of(self, db, nick): + nick = normalize(nick) cur = db.execute("SELECT points FROM Points WHERE nick=?", (nick,)) res = cur.fetchone()