replace into instead of update
This commit is contained in:
parent
81e8e2de9a
commit
a51f9f66c1
1 changed files with 2 additions and 2 deletions
|
@ -82,8 +82,8 @@ class SQLStorage():
|
|||
self.conn.commit()
|
||||
|
||||
def update_feed(self, feed, values):
|
||||
self.conn.execute("""UPDATE feeds SET title=?, favicon=?, etag=?, lastmodified=?, unread=? WHERE feed=?""",
|
||||
(values['title'], values.get('favicon'), values.get('etag'), values.get('lastmodified'), values['unread'], feed))
|
||||
self.conn.execute("""REPLACE INTO feeds (feed, title, favicon, etag, lastmodified, unread) VALUES (?,?,?,?,?,?)""",
|
||||
(feed, values['title'], values.get('favicon'), values.get('etag'), values.get('lastmodified'), values['unread']))
|
||||
self.conn.commit()
|
||||
|
||||
def set_favicon(self, feed, favicon):
|
||||
|
|
Loading…
Reference in a new issue