org-macro: Small refactoring

* lisp/org-macro.el (org-macro-initialize-templates): Remove spurious
  lambda funcall.
This commit is contained in:
Nicolas Goaziou 2015-03-24 09:44:27 +01:00
parent 359572d37e
commit 2f58e3c011
1 changed files with 2 additions and 2 deletions

View File

@ -125,12 +125,12 @@ function installs the following ones: \"property\",
(if old-template (setcdr old-template (cdr cell))
(push cell templates))))))
;; Install hard-coded macros.
(mapc (lambda (cell) (funcall update-templates cell))
(mapc update-templates
(list (cons "property" "(eval (org-entry-get nil \"$1\" 'selective))")
(cons "time" "(eval (format-time-string \"$1\"))")))
(let ((visited-file (buffer-file-name (buffer-base-buffer))))
(when (and visited-file (file-exists-p visited-file))
(mapc (lambda (cell) (funcall update-templates cell))
(mapc update-templates
(list (cons "input-file" (file-name-nondirectory visited-file))
(cons "modification-time"
(format "(eval (format-time-string \"$1\" '%s))"