From edcd36b912009573307446b5ce97b77fff955fff Mon Sep 17 00:00:00 2001 From: Thanos Apollo Date: Sun, 21 Jul 2024 16:01:49 +0300 Subject: [fix] gnosis-review: Encapsulate update of db. * All updates of the db should be done within gnosis-review--update. --- gnosis.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnosis.el b/gnosis.el index 1c3881d..bee4d15 100644 --- a/gnosis.el +++ b/gnosis.el @@ -1450,6 +1450,8 @@ Returns a list of the form ((yyyy mm dd) (ef-increase ef-decrease ef-total))." SUCCESS is a boolean value, t for success, nil for failure." (let ((ef (cadr (gnosis-review-algorithm id success))) (next-rev (car (gnosis-review-algorithm id success)))) + ;; Update activity-log + (gnosis-review-increment-activity-log) ;; Update review-log (gnosis-update 'review-log `(= last-rev ',(gnosis-algorithm-date)) `(= id ,id)) (gnosis-update 'review-log `(= next-rev ',next-rev) `(= id ,id)) @@ -1595,8 +1597,7 @@ DATE: Date to log the note review on the activity-log." (progn (pop-to-buffer-same-window (get-buffer-create "*gnosis*")) (gnosis-mode) - (funcall func-name id) - (gnosis-review-increment-activity-log date)) + (funcall func-name id)) (error "Malformed note type: '%s'" type)))) -- cgit v1.2.3