From 406ad1e612201e7ba828188f5257617940626ee3 Mon Sep 17 00:00:00 2001 From: Thanos Apollo Date: Mon, 15 Jan 2024 22:01:24 +0200 Subject: [fix] Fix bug from 5fefd3d for multiple cloze review - Update note after all clozes have been revealed and add comment as reminder --- gnosis.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gnosis.el b/gnosis.el index a1199e2..a3f9ca0 100644 --- a/gnosis.el +++ b/gnosis.el @@ -975,7 +975,6 @@ Used to reveal all clozes left with `gnosis-face-cloze-unanswered' face." (if (equal (car input) t) ;; Reveal only one cloze (progn (gnosis-display-cloze-reveal :replace cloze) - (gnosis-review--update id 1) (setf num (1+ num))) ;; Reveal cloze for wrong input, with `gnosis-face-false' (gnosis-display-cloze-reveal :replace cloze :success nil) @@ -985,7 +984,9 @@ Used to reveal all clozes left with `gnosis-face-cloze-unanswered' face." (when (< num clozes-num) (gnosis-review-cloze-reveal-unaswered clozes)) (gnosis-display-cloze-user-answer (cdr input)) (gnosis-review--update id 0) - (cl-return))))) + (cl-return))) + ;; Update note after all clozes are revealed successfully + finally (gnosis-review--update id 1))) (gnosis-display--extra id) (gnosis-display--next-review id)) -- cgit v1.2.3