From 1fc19ce5bc127f2f1ab00718f829656daec3b328 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sat, 22 Sep 2012 11:08:20 +0200 Subject: [PATCH] org-capture.el (org-capture-fill-template): Fix checking of protected template entries * org-capture.el (org-capture-fill-template): Fix checking of protected template entries. Thanks to Myles English for spotting this. --- lisp/org-capture.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/org-capture.el b/lisp/org-capture.el index 79e5a5d3d..49ab60c4b 100644 --- a/lisp/org-capture.el +++ b/lisp/org-capture.el @@ -1486,7 +1486,7 @@ The template may still contain \"%?\" for cursor positioning." ;; Interactive template entries (goto-char (point-min)) (while (and (re-search-forward "%^\\({\\([^}]*\\)}\\)?\\([gGtTuUCLp]\\)?" nil t) - (not (get-text-property (point) 'org-protected))) + (not (get-text-property (1- (point)) 'org-protected))) (unless (org-capture-escaped-%) (setq char (if (match-end 3) (match-string-no-properties 3)) prompt (if (match-end 2) (match-string-no-properties 2)))