Skip to content

Commit f307090

Browse files
authored
fix!: sent emails not showing bug (#279) (#280)
1 parent ab8158e commit f307090

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

fetcher/fetcher.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,11 @@ func FetchMailboxEmails(account *config.Account, mailbox string, limit, offset u
298298

299299
matched := false
300300
if isSentMailbox {
301-
if strings.EqualFold(strings.TrimSpace(fromAddr), fetchEmail) {
301+
var senderEmail string
302+
if len(msg.Envelope.From) > 0 {
303+
senderEmail = msg.Envelope.From[0].Address()
304+
}
305+
if strings.EqualFold(strings.TrimSpace(senderEmail), fetchEmail) {
302306
matched = true
303307
}
304308
} else {

0 commit comments

Comments
 (0)