From be476c236e40dd0ba87be9d466dd5cd00a6960b7 Mon Sep 17 00:00:00 2001 From: Nicholas Vollmer Date: Fri, 25 Sep 2020 03:42:57 -0400 Subject: [PATCH] capture: Fix bare link "Args out of range" * lisp/org-capture.el (org-capture-fill-template): guard against empty annotation string --- 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 a6e95f24e..67c58ffdd 100644 --- a/lisp/org-capture.el +++ b/lisp/org-capture.el @@ -1595,7 +1595,7 @@ The template may still contain \"%?\" for cursor positioning." (v-l (if (and v-a (string-match l-re v-a)) (replace-match "[[\\1]]" nil nil v-a) v-a)) - (v-L (if (or v-a (string-match l-re v-a)) + (v-L (if (and v-a (string-match l-re v-a)) (replace-match "\\1" nil nil v-a) v-a)) (v-n user-full-name) -- 2.28.0