iens

Manager of links to read
git clone https://git.instinctive.eu/iens.git
Log | Files | Refs | README | LICENSE

commit cc9ff4617be560ff8a42bd6940a9610ce346d913
parent 336fd8bc9a80e9d328b04bf80acf941e68a55fd8
Author: Natasha Kerensikova <natgh@instinctive.eu>
Date:   Sun, 17 Mar 2024 14:17:56 +0000

Command `update-feed-cache` does not return a value
Diffstat:
Msrc/iens.scm | 14+++++---------
1 file changed, 5 insertions(+), 9 deletions(-)

diff --git a/src/iens.scm b/src/iens.scm @@ -424,12 +424,9 @@ id)) (old-sig (alist-ref id feed-cache = '()))) (if (null? data) - (begin - (write-line (conc "Feed #" id " does not exist")) - #f) - (let* ((new-sig (build-signature (cadr data))) - (changed (not (equal? old-sig new-sig)))) - (when changed + (write-line (conc "Feed #" id " does not exist")) + (let ((new-sig (build-signature (cadr data)))) + (unless (equal? old-sig new-sig) (when (or (null? (car data)) (> mtime (car data))) (touch-feed mtime id)) @@ -438,11 +435,10 @@ (write-diff (diff-signature old-sig new-sig))) (unless (any (cut = id <>) dirty-feeds) (set! dirty-feeds (cons id dirty-feeds))) - (set! feed-cache (alist-update! id new-sig feed-cache =))) - changed)))) + (set! feed-cache (alist-update! id new-sig feed-cache =))))))) (define (update-feed-cache mtime . id-list) - (filter + (for-each (cut update-feed-cache* mtime <>) (if (null? id-list) (query fetch-column (sql db "SELECT id FROM feed WHERE active=1;"))