瀏覽代碼

org-mobile: Fix Wrong type argument: sequencep, :startgrouptag

* lisp/org-mobile.el (org-mobile-create-index-file): Handle group tags.

Reported-by: John Hutchinson <johnrhutchinson@att.net>
<http://permalink.gmane.org/gmane.emacs.orgmode/105033>
Nicolas Goaziou 9 年之前
父節點
當前提交
28d3e729e4
共有 1 個文件被更改,包括 10 次插入8 次删除
  1. 10 8
      lisp/org-mobile.el

+ 10 - 8
lisp/org-mobile.el

@@ -454,14 +454,16 @@ agenda view showing the flagged items."
 	(insert "#+TODO: " (mapconcat 'identity todo-kwds " ") " | "
 		(mapconcat 'identity done-kwds " ") "\n"))
       (setq def-tags (mapcar
-		      (lambda (x)
-			(cond ((null x) nil)
-			      ((stringp x) x)
-			      ((eq (car x) :startgroup) "{")
-			      ((eq (car x) :endgroup) "}")
-			      ((eq (car x) :grouptags) nil)
-			      ((eq (car x) :newline) nil)
-			      ((listp x) (car x))))
+		      (lambda (tag)
+			(cl-case (car tag)
+			  ((nil) nil)
+			  (:startgroup "{")
+			  (:endgroup "}")
+			  (:startgrouptag "[")
+			  (:endgrouptag "]")
+			  (:grouptags ":")
+			  (:newline nil)
+			  (t (car tag))))
 		      def-tags))
       (setq def-tags (delq nil def-tags))
       (setq tags (org-delete-all def-tags tags))