diff options
author | André Glüpker <git@wgmd.de> | 2024-05-25 10:50:42 +0200 |
---|---|---|
committer | André Glüpker <git@wgmd.de> | 2024-05-25 10:50:42 +0200 |
commit | 06cc74328009a896116c77c10c5687eade66ff7d (patch) | |
tree | 786e0ca88470bc90db1ef6e5baae6837ac1ad05a /urldelta.py | |
parent | 24eb5ad088b365c4189003282014403b74ad2249 (diff) | |
download | rss-feeds-06cc74328009a896116c77c10c5687eade66ff7d.tar.gz rss-feeds-06cc74328009a896116c77c10c5687eade66ff7d.tar.bz2 rss-feeds-06cc74328009a896116c77c10c5687eade66ff7d.zip |
Fix change detection - compare against latest only
Diffstat (limited to 'urldelta.py')
-rwxr-xr-x | urldelta.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/urldelta.py b/urldelta.py index d45a442..1808615 100755 --- a/urldelta.py +++ b/urldelta.py @@ -62,7 +62,7 @@ def get_page_delta(url): data = cursor.fetchone() if data: id, last_fetched = data - cursor.execute("SELECT content FROM deltas WHERE website_id = ?", (id,)) + cursor.execute("SELECT content FROM deltas WHERE website_id = ? ORDER BY fetch_date desc LIMIT 1", (id,)) last_content = cursor.fetchone() if last_content: last_content = last_content[0] |