diff options
| author | Eric Abrahamsen <eric@ericabrahamsen.net> | 2023-01-08 11:01:32 -0800 |
|---|---|---|
| committer | Eric Abrahamsen <eric@ericabrahamsen.net> | 2023-01-08 11:01:32 -0800 |
| commit | 409e4fc2c83f8406f362028dbcc3a1fc21182819 (patch) | |
| tree | 4aee21eabec77fce16caf5589cb490c193b32d78 | |
| parent | 35d8a5090b06e9d451eeaf46567e6934a4d11b3d (diff) | |
Handle org-agenda-type 'tags with no tags, release 1.6.11externals/gnorb
* gnorb-org.el (gnorb-org-popup-bbdb): When popping up BBDB for org
agenda searches, the 'tags type of seach might only have properties in
the search string, no tags. If no tags are found, return silently.
| -rw-r--r-- | gnorb-org.el | 7 | ||||
| -rw-r--r-- | gnorb.el | 2 |
2 files changed, 5 insertions, 4 deletions
diff --git a/gnorb-org.el b/gnorb-org.el index 6ae35ee..84f6757 100644 --- a/gnorb-org.el +++ b/gnorb-org.el @@ -728,7 +728,8 @@ Returns a lambda form used for matching a search string (ie, the (setq term rest))) (push (mapconcat 'identity (nreverse acc) "") out-or)) (setq str (mapconcat 'identity (nreverse out-or) "|")) - (cdr (org-make-tags-matcher str)))) + (when (not (string-blank-p str)) + (cdr (org-make-tags-matcher str))))) ;;;###autoload (defun gnorb-org-popup-bbdb (&optional str) @@ -743,8 +744,8 @@ search." (eq org-agenda-type 'tags)) (or (called-interactively-p 'any) gnorb-org-agenda-popup-bbdb)) - (let ((tag-clause (gnorb-org-munge-agenda-query-string - (or str org-agenda-query-string)))) + (when-let ((tag-clause (gnorb-org-munge-agenda-query-string + (or str org-agenda-query-string)))) (unless (equal str "") (setq recs (cl-remove-if-not @@ -2,7 +2,7 @@ ;; Copyright (C) 2018-2020 Free Software Foundation, Inc. -;; Version: 1.6.10 +;; Version: 1.6.11 ;; Package-Requires: ((cl-lib "0.5")) ;; Maintainer: Eric Abrahamsen <eric@ericabrahamsen.net> |
