branch: externals/denote
commit 991abe5b65f07930830b02355771ac893af859c5
Author: Protesilaos Stavrou <[email protected]>
Commit: Protesilaos Stavrou <[email protected]>
Use denote--file-empty-p
Added in commit 387ac0c.
---
denote-org-capture.el | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/denote-org-capture.el b/denote-org-capture.el
index 5999f3aef9..17e5780dbc 100644
--- a/denote-org-capture.el
+++ b/denote-org-capture.el
@@ -68,7 +68,7 @@ sample template. We will eventually have a manual."
(defun denote-org-capture-delete-empty-file ()
"Delete file if capture with `denote-org-capture' is aborted."
(when-let* ((file denote-last-path)
- ((zerop (or (file-attribute-size (file-attributes file)) 0))))
+ ((denote--file-empty-p file)))
(delete-file denote-last-path)))
;; Samples of an `org-capture-templates' entry: