mu4e-actions: fix mu4e~write-body-to-html

Use mu4e~view-construct-contacts-header instead of a non-existing
function.
This commit is contained in:
djcb 2019-04-15 07:19:44 +03:00
parent 46c3c5a49b
commit da1cb4e97b
1 changed files with 6 additions and 3 deletions

View File

@ -85,9 +85,12 @@ return the filename."
(mu4e-error "No body part for this message"))
(with-temp-buffer
(insert "<head><meta charset=\"UTF-8\"></head>\n")
(insert (concat "<p><strong>From</strong>: " (mu4e-html-construct-contacts-header msg :from) "</br>"))
(insert (concat "<strong>To</strong>: " (mu4e-html-construct-contacts-header msg :to) "</br>"))
(insert (concat "<strong>Date</strong>: " (format-time-string mu4e-view-date-format (mu4e-message-field msg :date)) "</br>"))
(insert (concat "<p><strong>From</strong>: "
(mu4e~view-construct-contacts-header msg :from) "</br>"))
(insert (concat "<strong>To</strong>: "
(mu4e~view-construct-contacts-header msg :to) "</br>"))
(insert (concat "<strong>Date</strong>: "
(format-time-string mu4e-view-date-format (mu4e-message-field msg :date)) "</br>"))
(insert (concat "<strong>Subject</strong>: " (mu4e-message-field msg :subject) "</p>"))
(insert (or html (concat "<pre>" txt "</pre>")))
(write-file tmpfile)