From d24fce1dcd3e3ecf712a93333f715e59cce9ce0c Mon Sep 17 00:00:00 2001 From: Henrik Lissner Date: Wed, 29 Aug 2018 16:45:09 +0200 Subject: [PATCH] Fix void-variable org-capture-is-refiling error In case org-capture.el isn't loaded when org-refile is used. --- modules/lang/org/+capture.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/lang/org/+capture.el b/modules/lang/org/+capture.el index 988b71400..4c7025664 100644 --- a/modules/lang/org/+capture.el +++ b/modules/lang/org/+capture.el @@ -37,7 +37,7 @@ ;; fix #462: when refiling from org-capture, Emacs prompts to kill the ;; underlying, modified buffer. This fixes that. (defun +org-capture*refile (&rest _) - (when org-capture-is-refiling + (when (bound-and-true-p org-capture-is-refiling) (org-save-all-org-buffers))) (advice-add 'org-refile :after #'+org-capture*refile)