branch: externals/org commit 6a5874bb26c028640ce689f93b64cea9874ff637 Author: Ihor Radchenko <yanta...@gmail.com> Commit: Ihor Radchenko <yanta...@gmail.com>
org-persist-write: Overwrite existing copy if write is requested --- lisp/org-persist.el | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/lisp/org-persist.el b/lisp/org-persist.el index 3495485844..099b4aff8a 100644 --- a/lisp/org-persist.el +++ b/lisp/org-persist.el @@ -634,8 +634,7 @@ COLLECTION is the plist holding data collectin." (format "%s-%s.%s" persist-file (md5 path) ext)))) (unless (file-exists-p (file-name-directory file-copy)) (make-directory (file-name-directory file-copy) t)) - (unless (file-exists-p file-copy) - (copy-file path file-copy 'overwrite)) + (copy-file path file-copy 'overwrite) (format "%s-%s.%s" persist-file (md5 path) ext))))) (defun org-persist-write:url (c collection) @@ -650,8 +649,7 @@ COLLECTION is the plist holding data collectin." (format "%s-%s.%s" persist-file (md5 path) ext)))) (unless (file-exists-p (file-name-directory file-copy)) (make-directory (file-name-directory file-copy) t)) - (unless (file-exists-p file-copy) - (url-copy-file path file-copy 'overwrite)) + (url-copy-file path file-copy 'overwrite) (format "%s-%s.%s" persist-file (md5 path) ext))))) (defun org-persist-write:index (container _)