From 8c82c8f104ff0013e2bfb3d6b4277280f32446a6 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Fri, 4 Dec 2020 13:02:10 +0100 Subject: messages: issue-messages: Prefer the active log. * mumi/messages.scm (issue-messages): If the active log exists use it for issue messages. --- mumi/messages.scm | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/mumi/messages.scm b/mumi/messages.scm index ae39b9a..25425a3 100644 --- a/mumi/messages.scm +++ b/mumi/messages.scm @@ -186,9 +186,12 @@ result for a while." (bug-id->log-file bug-id #:archived? #t)) (define active-log (bug-id->log-file bug-id)) + ;; Prefer the active log over the archived log. This is useful if + ;; the bug has been unarchived. The mere existence of an archived + ;; log does not mean that the bug is *currently* archived. (define file - (or (and (file-exists? archived-log) archived-log) - (and (file-exists? active-log) active-log))) + (or (and (file-exists? active-log) active-log) + (and (file-exists? archived-log) archived-log))) (if file (let ((key (list 'issue-messages bug-id))) (or (cached? key) -- cgit v1.2.3