Browse Source

org-agenda: Fix category string for agenda

* lisp/org-agenda.el: (org-format-agenda-item) The value of
org-category is not converted to a string unless it is defined.

This fixes commit 3061c7083d8caa849cf2d3f2f53b8b71d45dd6de, which
resulted in org-format-agenda-item always returning the symbol-name for
org-category even if it was not defined. I.e., in some instances,
org-format-agenda-item returned the string "nil", thus bypassing the
buffer-file-name method of deriving the category.
Matt Lundin 14 years ago
parent
commit
2ac751a6cb
1 changed files with 1 additions and 1 deletions
  1. 1 1
      lisp/org-agenda.el

+ 1 - 1
lisp/org-agenda.el

@@ -5097,7 +5097,7 @@ Any match of REMOVE-RE will be removed from TXT."
     (let* ((category (or category
 			 (if (stringp org-category)
 			     org-category
-			   (symbol-name org-category))
+			   (and org-category (symbol-name org-category)))
 			 (if buffer-file-name
 			     (file-name-sans-extension
 			      (file-name-nondirectory buffer-file-name))