only save newer tweets, don't override with older
This commit is contained in:
parent
2d12aa7107
commit
2a4d517f1d
1
user.py
1
user.py
|
@ -170,6 +170,7 @@ schlitz
|
||||||
return db.cur.fetchone()[0]
|
return db.cur.fetchone()[0]
|
||||||
|
|
||||||
def save_seen_tweet(self, tweet_id):
|
def save_seen_tweet(self, tweet_id):
|
||||||
|
if tweet_id > self.get_seen_tweet():
|
||||||
db.execute("UPDATE seen_tweets SET tweet_id = ? WHERE user_id = ?;",
|
db.execute("UPDATE seen_tweets SET tweet_id = ? WHERE user_id = ?;",
|
||||||
(tweet_id, self.uid))
|
(tweet_id, self.uid))
|
||||||
db.commit()
|
db.commit()
|
||||||
|
|
Loading…
Reference in a new issue