small pixel drawing of a pufferfish clist

Add References, make In-Reply-To RFC compliant
j3s j3s@cyberia.club
Fri, 06 Dec 2019 19:21:32 -0600
commit

f4b39221d293d857f6eb08727a2dd1a37c368c5b

parent

a936f70768ae8b088e9206f51f8b38d55fbae8d6

1 files changed, 4 insertions(+), 1 deletions(-)

jump to
M mail/main.gomail/main.go

@@ -453,7 +453,10 @@ if len(e.MessageID) > 0 {

fmt.Fprintf(&buf, "Message-ID: %s\r\n", e.MessageID) } if len(e.InReplyTo) > 0 { - fmt.Fprintf(&buf, "In-Reply-To: %s\r\n", strings.Join(e.InReplyTo, ",")) + fmt.Fprintf(&buf, "In-Reply-To: <%s>\r\n", strings.Join(e.InReplyTo, "> <")) + } + if len(e.References) > 0 { + fmt.Fprintf(&buf, "References: <%s>\r\n", strings.Join(e.References, "> <")) } if len(e.Header.Get("List-Id")) > 0 { fmt.Fprintf(&buf, "List-Id: %s\r\n", e.Header.Get("List-Id"))