go-gomail / gomail

The best way to send emails in Go.
MIT License
4.33k stars 573 forks source link

Bugfix. BCC should not be added in header #34

Closed mpdroog closed 9 years ago

mpdroog commented 9 years ago
msg.SetHeader("Bcc", []string{"me@secret.com"})

When I add this secret address in the BCC-header field it should not be added in the email, currently this is the case.

alexcesaro commented 9 years ago

Gomail currently send the Bcc header only to the recipient in the Bcc field which is one of the 3 ways defined in RFC to handle that field.

Gomail v2 will remove the Bcc field but I will not change how Gomail v1 currently works.

Did you get a problem with the Bcc field or did you misunderstand how Gomail currently works?

mpdroog commented 9 years ago

Thnx for the quick reply. Hmm your right, I didn't look close enough sorry!

I thought I got a problem with the Bcc-field but I see now I didn't notice the subtle difference (both mails came into the same mailbox)

Might be a idea to add a small note about this behaviour in the documentation?