Skip to content

Commit

Permalink
mu4e-compose: copy message-reply-headers to fake buffer
Browse files Browse the repository at this point in the history
We need copy the buffer-local value from _another_ buffer

HT: Martin R. Albrecht.
  • Loading branch information
djcb committed Mar 13, 2024
1 parent 0e05ab8 commit 6d9cf64
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions mu4e/mu4e-compose.el
Original file line number Diff line number Diff line change
Expand Up @@ -734,9 +734,13 @@ Based on the value of `mu4e-compose-switch'."
This is a little glue to use `message-reply', `message-forward'
etc. We cannot use the normal `message-pop-to-buffer' since we're
not ready yet to show the buffer in mu4e."
(set-buffer (get-buffer-create name))
(erase-buffer)
(current-buffer))
;; note: we're in a _different_ buffer here, so we need to copy
;; message-reply-header's buffer-local value.
(let ((reply-headers message-reply-headers))
(set-buffer (get-buffer-create name))
(setq-local message-reply-headers reply-headers)
(erase-buffer)
(current-buffer)))

(defun mu4e--headers (compose-type)
"Determine headers needed for message."
Expand Down

0 comments on commit 6d9cf64

Please sign in to comment.