diff options
author | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2019-03-10 11:14:52 +0100 |
---|---|---|
committer | Nicolas Goaziou <mail@nicolasgoaziou.fr> | 2019-03-10 11:14:52 +0100 |
commit | e84006ea4eee098854207a5fece2e06129b9ccdc (patch) | |
tree | 1a28aca251dbae278e069e2ff2183d4dde73f043 | |
parent | 56b7c5ba59903bbbb96c16f5bf10d22ea1f0822d (diff) | |
parent | 116a58b368773638186867931ec030152569e398 (diff) | |
download | org-mode-e84006ea4eee098854207a5fece2e06129b9ccdc.tar.gz |
Merge branch 'maint'
-rw-r--r-- | lisp/org-agenda.el | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el index b3e0dba..1f7eda1 100644 --- a/lisp/org-agenda.el +++ b/lisp/org-agenda.el @@ -7003,7 +7003,8 @@ The optional argument TYPE tells the agenda type." "\\([ \t]*\\[[a-zA-Z0-9]\\]\\)? *") tb) (setq tb (substring tb (match-end 0)))) (setq tb (downcase tb))) - (cond ((not ta) +1) + (cond ((not (or ta tb)) nil) + ((not ta) +1) ((not tb) -1) ((string-lessp ta tb) -1) ((string-lessp tb ta) +1)))) @@ -7012,7 +7013,8 @@ The optional argument TYPE tells the agenda type." "Compare the string values of the first tags of A and B." (let ((ta (car (last (get-text-property 1 'tags a)))) (tb (car (last (get-text-property 1 'tags b))))) - (cond ((not ta) +1) + (cond ((not (or ta tb)) nil) + ((not ta) +1) ((not tb) -1) ((string-lessp ta tb) -1) ((string-lessp tb ta) +1)))) |