From 4ce2ad4eb18d736e6358b447513586884b7f216e Mon Sep 17 00:00:00 2001 From: Ihor Radchenko Date: Wed, 17 Jan 2024 12:52:37 +0100 Subject: [PATCH] lisp/org.el (org-agenda-files): Avoid duplicates Duplicate entries in agenda files cause scanning the same file twice, producing duplicates in the agenda. Reported-by: Christopher M. Miles Link: https://orgmode.org/list/65a75fd3.170a0220.be4f3.67c9@mx.google.com --- lisp/org.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/org.el b/lisp/org.el index 6c9ff3026..bd4537f5a 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -15419,7 +15419,7 @@ used by the agenda files. If ARCHIVE is `ifmode', do this only if (when (or (eq archives t) (and (eq archives 'ifmode) (eq org-agenda-archives-mode t))) (setq files (org-add-archive-files files))) - files)) + (delete-dups files))) (defun org-agenda-file-p (&optional file) "Return non-nil, if FILE is an agenda file.