From 0d1cca191bd054516fa70d5715996ea085a0dde6 Mon Sep 17 00:00:00 2001 From: Drew DeVault Date: Fri, 13 Nov 2020 10:32:02 -0500 Subject: alps/compose.html: fix message ID --- plugins/base/smtp.go | 3 +++ 1 file changed, 3 insertions(+) (limited to 'plugins/base') diff --git a/plugins/base/smtp.go b/plugins/base/smtp.go index 50a2fd0..40967dc 100644 --- a/plugins/base/smtp.go +++ b/plugins/base/smtp.go @@ -172,6 +172,9 @@ func (msg *OutgoingMessage) WriteTo(w io.Writer) error { } h.Set("Message-Id", msg.MessageID) + if msg.MessageID == "" { + panic(fmt.Errorf("Attempting to send message without message ID")) + } mw, err := mail.CreateWriter(w, h) if err != nil { -- cgit v1.2.3