org-capture.el (org-capture-refile): Don't finalize prematurely

* org-capture.el (org-capture-refile): Don't finalize
prematurely.

Thanks to Rodrigo Amestica for reporting this.
This commit is contained in:
Bastien Guerry 2013-11-06 16:26:38 +01:00
parent fe3379bda6
commit 47b0eec8dc
1 changed files with 2 additions and 2 deletions

View File

@ -789,14 +789,14 @@ already gone. Any prefix argument will be passed to the refile command."
(let ((pos (point))
(base (buffer-base-buffer (current-buffer)))
(org-refile-for-capture t))
(org-capture-finalize)
(save-window-excursion
(with-current-buffer (or base (current-buffer))
(save-excursion
(save-restriction
(widen)
(goto-char pos)
(call-interactively 'org-refile)))))))
(call-interactively 'org-refile)))))
(org-capture-finalize)))
(defun org-capture-kill ()
"Abort the current capture process."