repaired seen_tweets
This commit is contained in:
parent
b35e885ae2
commit
03033d26d7
5
db.py
5
db.py
|
@ -109,11 +109,8 @@ class DB(object):
|
|||
CREATE TABLE IF NOT EXISTS seen_tweets (
|
||||
id INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT UNIQUE,
|
||||
user_id INTEGER,
|
||||
twitter_accounts_id INTEGER,
|
||||
tweet_id TEXT,
|
||||
FOREIGN KEY(user_id) REFERENCES user(id)
|
||||
FOREIGN KEY(twitter_accounts_id)
|
||||
REFERENCES twitter_accounts(id)
|
||||
);
|
||||
CREATE TABLE IF NOT EXISTS seen_dms (
|
||||
id INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT UNIQUE,
|
||||
|
@ -264,6 +261,8 @@ u\d\d?"""
|
|||
"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.commit()
|
||||
user = User(uid)
|
||||
user.set_city(city)
|
||||
|
|
Loading…
Reference in a new issue