0
0
Fork 1
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-08-20 08:48:39 +00:00

org-capture: use org-eval

* org-capture.el (org-capture-fill-template): Use org-eval.
This commit is contained in:
Julien Danjou 2010-12-17 22:18:14 +00:00 committed by Carsten Dominik
parent 2c1925f2a5
commit f73b121549

View file

@ -1206,10 +1206,7 @@ The template may still contain \"%?\" for cursor positioning."
(goto-char (match-beginning 0))
(let ((template-start (point)))
(forward-char 1)
(let ((result
(condition-case error
(eval (read (current-buffer)))
(error (format "%%![Error: %s]" error)))))
(let ((result (org-eval (read (current-buffer)))))
(delete-region template-start (point))
(insert result)))))