From 944fd9d651633e2137ba75de6b6fe6b85aa75897 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Mon, 13 Aug 2012 23:53:18 +0200 Subject: [PATCH] org.el: Fix bug in `org-fill-template' * org.el (org-fill-template): Fix bug when filling template for a key associated to the nil value. Thanks to Ken Williams for reporting this. --- lisp/org.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/org.el b/lisp/org.el index 611b7a58f..c9b61757e 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -20152,7 +20152,7 @@ N may optionally be the number of spaces to remove." (setq template (replace-regexp-in-string (concat "%" (regexp-quote (car entry))) - (cdr entry) template t t))) + (or (cdr entry) "") template t t))) template)) (defun org-base-buffer (buffer)