func sendjob(job model.Job, t time.Time) bool { user := job.User() buf := new(bytes.Buffer) fmt.Fprintf(buf, "From: %s\n", MailFrom) fmt.Fprintf(buf, "To: %s\n", user.Email()) fmt.Fprintf(buf, "Subject: %s\n", job.Subject()) fmt.Fprintf(buf, "Date: %s\n", t.In(user.Location()).Format(time.RFC1123Z)) fmt.Fprintln(buf, "") buf.Write(job.Content()) return Mail(user.Email(), MailFrom, buf.Bytes()) }