diff options
author | David Florness <david@florness.com> | 2021-01-04 23:20:51 -0500 |
---|---|---|
committer | stardiviner <numbchild@gmail.com> | 2021-01-05 19:28:11 +0800 |
commit | 38f143830c9a374440c040d161b962ae4fa0e74e (patch) | |
tree | c40f20c64424bdbc07e7d27d75e81aece4745ff3 | |
parent | 00b4de3294e526f9684c7669f9697b2fe27e13e1 (diff) | |
download | org-mode-38f143830c9a374440c040d161b962ae4fa0e74e.tar.gz |
org-contacts.el: Use `bound-and-true-p' to check (unbound) var
* org-contacts.el (org-contacts-link-store): Use `bound-and-true-p' to
check the truthiness of org-id-link-to-org-use-id, which may or may
not be bound depending on whether org-id has been loaded. This
simplifies the code.
-rw-r--r-- | contrib/lisp/org-contacts.el | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/contrib/lisp/org-contacts.el b/contrib/lisp/org-contacts.el index 7ad4255..3df1b52 100644 --- a/contrib/lisp/org-contacts.el +++ b/contrib/lisp/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 (and (featurep 'org-id) org-id-link-to-org-use-id) + (if (bound-and-true-p 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 |