branch: externals/gnorb
commit 409e4fc2c83f8406f362028dbcc3a1fc21182819
Author: Eric Abrahamsen <e...@ericabrahamsen.net>
Commit: Eric Abrahamsen <e...@ericabrahamsen.net>

    Handle org-agenda-type 'tags with no tags, release 1.6.11
    
    * 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.
---
 gnorb-org.el | 7 ++++---
 gnorb.el     | 2 +-
 2 files changed, 5 insertions(+), 4 deletions(-)

diff --git a/gnorb-org.el b/gnorb-org.el
index 6ae35ee59d..84f6757088 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
diff --git a/gnorb.el b/gnorb.el
index e1ee4d600f..91b230c951 100644
--- a/gnorb.el
+++ b/gnorb.el
@@ -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 <e...@ericabrahamsen.net>

Reply via email to