summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCarsten Dominik <carsten.dominik@gmail.com>2019-08-12 13:30:38 +0200
committerCarsten Dominik <carsten.dominik@gmail.com>2019-08-12 13:30:38 +0200
commitf5d27e046a849bac7856e6fe97457961af015786 (patch)
tree1ddc90cab7527fa344feb91f71748008dd17c114
parente3856a0c8ed134ce21659ceb0bec75479506e1ea (diff)
downloadorg-mode-f5d27e046a849bac7856e6fe97457961af015786.tar.gz
Fix bug dealing with the width field of categories in agenda
lisp/org-agenda.el (org-compile-prefix-format): Fix bug dealing with the width field of categories. Fix by Héctor Enríquez Ramón.
-rw-r--r--lisp/org-agenda.el5
1 files changed, 3 insertions, 2 deletions
diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el
index f1a99bc..dbe5042 100644
--- a/lisp/org-agenda.el
+++ b/lisp/org-agenda.el
@@ -6739,8 +6739,9 @@ and stored in the variable `org-prefix-format-compiled'."
(floor (abs (string-to-number (match-string 2 s)))))
(setq org-prefix-category-max-length
(let ((x (match-string 2 s)))
- (when (string-match-p "\\.[0-9]+" x)
- (string-to-number (substring (match-string 0 x) 1))))))
+ (save-match-data
+ (and (string-match "\\.[0-9]+" x)
+ (string-to-number (substring (match-string 0 x) 1)))))))
(if (eq var 'eval)
(setq varform `(format ,f (org-eval ,(read (match-string 4 s)))))
(if opt