From 0449d892a30cbb2b1ff27ebb1b2218bdff26b881 Mon Sep 17 00:00:00 2001 From: b3yond Date: Sun, 7 Oct 2018 22:16:00 +0200 Subject: [PATCH] insert empty row at account creation --- db.py | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/db.py b/db.py index d8c3275..8ca509f 100644 --- a/db.py +++ b/db.py @@ -257,12 +257,10 @@ u\d\d?""" (uid, json['email'])) self.execute("""INSERT INTO telegram_accounts (user_id, apikey, active) VALUES(?, ?, ?);""", (uid, "", 1)) - self.execute( - "INSERT INTO seen_telegrams (user_id, tg_id) VALUES (?, ?);", (uid, 0)) - self.execute( - "INSERT INTO seen_mail (user_id, mail_date) VALUES (?, ?);", (uid, 0)) - self.execute("INSERT INTO seen_tweets (user_id, tweet_id) VALUES (?, ?)", - (uid, 0)) + self.execute("INSERT INTO seen_telegrams (user_id, tg_id) VALUES (?, ?);", (uid, 0)) + self.execute("INSERT INTO seen_mail (user_id, mail_date) VALUES (?, ?);", (uid, 0)) + self.execute("INSERT INTO seen_tweets (user_id, tweet_id) VALUES (?, ?)", (uid, 0)) + self.execute("INSERT INTO twitter_last_request (user_id, date) VALUES (?, ?)", (uid, 0)) self.commit() user = User(uid) user.set_city(city)