From eedaff34982e9e44a6d70677ba213f6c0d07c9ae Mon Sep 17 00:00:00 2001 From: David Florness Date: Sun, 3 Jan 2021 18:09:18 -0500 Subject: [PATCH] org-contacts.el: Only use org-id-store-link if org-id is loaded Fixes bug introduced in c8ceb5290 that made org-contacts-anniversaries error if org-id was not loaded. --- org-contacts.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/org-contacts.el b/org-contacts.el index 82881ec..7ad4255 100644 --- a/org-contacts.el +++ b/org-contacts.el @@ -1166,7 +1166,7 @@ are effectively trimmed). If nil, all zero-length substrings are retained." "Store the contact in `org-contacts-files' with a link." (when (and (eq major-mode 'org-mode) (member (buffer-file-name) (mapcar 'expand-file-name org-contacts-files))) - (if org-id-link-to-org-use-id + (if (and (featurep 'org-id) org-id-link-to-org-use-id) (org-id-store-link) (let ((headline-str (substring-no-properties (org-get-heading t t t t)))) (org-store-link-props