Browse Source

Merge pull request #593 from mcheng89/dev

check for smtp AUTH extension
pull/594/merge
无闻 10 years ago
parent
commit
beb8a77fc5
  1. 2
      modules/mailer/mailer.go

2
modules/mailer/mailer.go

@ -82,7 +82,7 @@ func sendMail(hostAddressWithPort string, auth smtp.Auth, from string, recipient
return err
}
if auth != nil {
if ok, _ := client.Extension("AUTH"); ok && auth != nil {
if err = client.Auth(auth); err != nil {
return err
}

Loading…
Cancel
Save