aerc

Working clone of aerc-mail.org
git clone git://git.danielmoch.com/aerc.git
Log | Files | Refs | README | LICENSE

commit 23650ac0c7173fcecfc727f1f4db52aeb168a3b9
parent e436780b4746fc7eb2dbbd804e4d7dc5cf5fef63
Author: Drew DeVault <sir@cmpwn.com>
Date:   Fri, 17 May 2019 11:05:21 -0400

Fix date header on outgoing emails

Diffstat:
Mwidgets/compose.go | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/widgets/compose.go b/widgets/compose.go @@ -221,7 +221,7 @@ func (c *Composer) PrepareHeader() (*mail.Header, []string, error) { if subject, _ := header.Subject(); subject == "" { header.SetSubject(c.headers.subject.input.String()) } - if date, err := header.Date(); err != nil && date != (time.Time{}) { + if date, err := header.Date(); err != nil || date == (time.Time{}) { header.SetDate(time.Now()) } if from, _ := mhdr.Text("From"); from == "" {