mu4e-compose: return new buffer from mu4e--compose-setup

I.e, and this applies to all mu4e-compose-* composition functions as
well.

Fixes #2653.
This commit is contained in:
Dirk-Jan C. Binnema
2024-03-03 09:42:58 +02:00
parent 131f084677
commit e28c2487d3

View File

@ -747,7 +747,9 @@ COMPOSE-FUNC is a function / lambda to create the specific type
of message.
Optionally, SWITCH determines how to find a buffer for the message
(see SWITCH-FUNCTION in `compose-mail')."
(see SWITCH-FUNCTION in `compose-mail').
Returns the new buffer."
(cl-assert (member compose-type '(reply forward edit new)))
(unless (mu4e-running-p) (mu4e 'background)) ;; start if needed
(let* ((parent
@ -775,7 +777,8 @@ Optionally, SWITCH determines how to find a buffer for the message
(setq-local ;;message-kill-actions actions
message-return-actions actions
message-send-actions actions
message-kill-actions actions)))))
message-kill-actions actions))
(current-buffer))))
;;;###autoload