Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose HasDSNExt Flag to determine if email is sent with "Fire and forget" or "Has been delivered" #109

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions email.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ type SMTPClient struct {
Client *smtpClient
SendTimeout time.Duration
KeepAlive bool
hasDSNExt bool
HasDSNExt bool
preserveOriginalRecipient bool
dsn []DSN
}
Expand Down Expand Up @@ -956,7 +956,7 @@ func (server *SMTPServer) Connect() (*SMTPClient, error) {
Client: c,
KeepAlive: server.KeepAlive,
SendTimeout: server.SendTimeout,
hasDSNExt: hasDSN,
HasDSNExt: hasDSN,
}, server.validateAuth(c)
}

Expand Down Expand Up @@ -1057,7 +1057,7 @@ func sendMailProcess(from string, to []string, msg string, c *SMTPClient) error
var dsn string
var dsnSet bool

if c.hasDSNExt && len(c.dsn) > 0 {
if c.HasDSNExt && len(c.dsn) > 0 {
dsn = " NOTIFY="
if hasNeverDSN(c.dsn) {
dsn += NEVER.String()
Expand Down