]> git.eshelyaron.com Git - emacs.git/commitdiff
When registering Gnus message ids, guard against no registry
authorEric Abrahamsen <eric@ericabrahamsen.net>
Mon, 6 Dec 2021 21:43:24 +0000 (13:43 -0800)
committerEric Abrahamsen <eric@ericabrahamsen.net>
Mon, 6 Dec 2021 21:45:27 +0000 (13:45 -0800)
* lisp/gnus/gnus-registry.el (gnus-registry-register-message-ids):
There are situations where this code is called without a full Gnus
startup (eg, debbugs). If the registry doesn't exist, just skip this
process.

lisp/gnus/gnus-registry.el

index 8ce88dc81e4350b9fd2f314e5e10b9d9e21baeea..163d543afd19dc565b55c65e1099e373450a407d 100644 (file)
@@ -847,7 +847,8 @@ Overrides existing keywords with FORCE set non-nil."
 (defun gnus-registry-register-message-ids ()
   "Register the Message-ID of every article in the group."
   (unless (or (gnus-parameter-registry-ignore gnus-newsgroup-name)
-             (null gnus-registry-register-all))
+             (null gnus-registry-register-all)
+              (null (eieio-object-p gnus-registry-db)))
     (dolist (article gnus-newsgroup-articles)
       (let* ((id (gnus-registry-fetch-message-id-fast article))
              (groups (gnus-registry-get-id-key id 'group)))