summary refs log tree commit diff stats
path: root/widgets
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2019-05-17 11:05:21 -0400
committerDrew DeVault <sir@cmpwn.com>2019-05-17 11:05:21 -0400
commit23650ac0c7173fcecfc727f1f4db52aeb168a3b9 (patch)
tree9c1c340ff93ff9d903a5f43a9d4bef38dbb9bd62 /widgets
parente436780b4746fc7eb2dbbd804e4d7dc5cf5fef63 (diff)
downloadaerc-23650ac0c7173fcecfc727f1f4db52aeb168a3b9.tar.gz
Fix date header on outgoing emails
Diffstat (limited to 'widgets')
-rw-r--r--widgets/compose.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/widgets/compose.go b/widgets/compose.go
index 18fe38c..31c0a2d 100644
--- 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 == "" {
/a> 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166