1
0
mirror of https://gitcode.com/gitea/gitea.git synced 2025-07-11 00:12:11 +08:00

Merge pull request from mcheng89/dev

check for smtp AUTH extension
This commit is contained in:
无闻
2014-10-31 22:18:15 -04:00

@ -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
}