branch: externals/denote
commit e9c44eec585b0e595cb348a84a87ab3b01d342a3
Author: Protesilaos Stavrou <[email protected]>
Commit: Protesilaos Stavrou <[email protected]>

    Use insert-buffer-substring instead of insert-buffer in 
denote--file-with-temp-buffer
    
    The function insert-buffer is meant to be for interactive use only.
    
    This follows the change made by duli in commit 0f71f12 via pull
    request 672: <https://github.com/protesilaos/denote/pull/672>. The
    author of the original change has assigned copyright to the Free
    Software Foundation.
    
    Also thanks to Jean-Philippe Gagné Guay for reviewing the change and
    for reporting a problem with an earlier version of the code in issue
    670: <https://github.com/protesilaos/denote/issues/670>.
---
 denote.el | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/denote.el b/denote.el
index 8634c94424..e5a4563973 100644
--- a/denote.el
+++ b/denote.el
@@ -2634,7 +2634,7 @@ BODY."
           (file-exist (file-exists-p ,file)))
      (with-temp-buffer
        (cond
-        (buffer (insert-buffer buffer))
+        (buffer (insert-buffer-substring buffer))
         (file-exist (insert-file-contents ,file))
         (t (error "Cannot find anything about file `%s'" ,file)))
        (goto-char (point-min))

Reply via email to