Browse Source

Merge branch 'maint' into master

Kyle Meyer 4 years ago
parent
commit
b64ba64feb
2 changed files with 10 additions and 5 deletions
  1. 5 5
      lisp/org.el
  2. 5 0
      testing/lisp/test-org.el

+ 5 - 5
lisp/org.el

@@ -1167,7 +1167,7 @@ are matched against file names, and values."
   "Alist between context and visibility span when revealing a location.
   "Alist between context and visibility span when revealing a location.
 
 
 \\<org-mode-map>Some actions may move point into invisible
 \\<org-mode-map>Some actions may move point into invisible
-locations.  As a consequence, Org always expose a neighborhood
+locations.  As a consequence, Org always exposes a neighborhood
 around point.  How much is shown depends on the initial action,
 around point.  How much is shown depends on the initial action,
 or context.  Valid contexts are
 or context.  Valid contexts are
 
 
@@ -4279,10 +4279,10 @@ related expressions."
       (setq org-current-tag-alist
       (setq org-current-tag-alist
 	    (org--tag-add-to-alist
 	    (org--tag-add-to-alist
 	     org-tag-persistent-alist
 	     org-tag-persistent-alist
-	     (let ((tags (mapconcat #'identity
-				    (cdr (assoc "TAGS" alist))
-				    "\n")))
-	       (if (org-string-nw-p tags) (org-tag-string-to-alist tags)
+	     (let ((tags (cdr (assoc "TAGS" alist))))
+	       (if tags
+		   (org-tag-string-to-alist
+		    (mapconcat #'identity tags "\n"))
 		 org-tag-alist))))
 		 org-tag-alist))))
       (setq org-tag-groups-alist
       (setq org-tag-groups-alist
 	    (org-tag-alist-to-groups org-current-tag-alist))
 	    (org-tag-alist-to-groups org-current-tag-alist))

+ 5 - 0
testing/lisp/test-org.el

@@ -2457,6 +2457,11 @@ SCHEDULED: <2014-03-04 tue.>"
 	    (org-test-with-temp-text "#+TAGS: [ A : B C ]"
 	    (org-test-with-temp-text "#+TAGS: [ A : B C ]"
 	      (org-mode-restart)
 	      (org-mode-restart)
 	      org-tag-groups-alist))))
 	      org-tag-groups-alist))))
+  (should-not
+   (let ((org-tag-alist '(("A"))))
+     (org-test-with-temp-text "#+TAGS:"
+       (org-mode-restart)
+       org-current-tag-alist)))
   ;; FILETAGS keyword.
   ;; FILETAGS keyword.
   (should
   (should
    (equal '("A" "B" "C")
    (equal '("A" "B" "C")