mirror of
https://github.com/protesilaos/denote.git
synced 2026-09-10 07:16:20 -04:00
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>.
This commit is contained in:
parent
927c862685
commit
e9c44eec58
|
|
@ -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))
|
||||
|
|
|
|||
Loading…
Reference in a new issue