mu4e-compose: kill fcc buffer after sending

There's a buried buffer for the fcc file... not quite sure why, but
let's kill it after we've sent the message.

Fixes #2681.
This commit is contained in:
Dirk-Jan C. Binnema 2024-04-11 20:02:01 +03:00
parent 8c29ed56ce
commit faade24945
1 changed files with 7 additions and 1 deletions

View File

@ -560,7 +560,13 @@ appropriate flag at the message forwarded or replied-to."
;; appropriate flag at the message forwarded or replied-to.
(add-hook 'message-sent-hook
(lambda ()
(mu4e--set-parent-flags fcc-path)) nil t))))
(mu4e--set-parent-flags fcc-path)
;; we end up with a ((buried) buffer here, visiting
;; the fcc-path; not quite sure why. But let's
;; get rid of it (#2681)
(when-let ((buf (find-buffer-visiting fcc-path)))
(kill-buffer buf)))
nil t))))
;;; Crypto
(defun mu4e--compose-setup-crypto (parent compose-type)