1
mirror of https://gitlab.com/commento/commento.git synced 2025-06-29 22:56:37 -04:00

api: add new config SMTP_PORT

This commit is contained in:
Adhityaa
2018-06-09 15:22:49 +05:30
parent 9d5e4f9f96
commit c794c40392
5 changed files with 6 additions and 3 deletions

View File

@ -12,7 +12,8 @@ func smtpConfigure() error {
username := os.Getenv("SMTP_USERNAME")
password := os.Getenv("SMTP_PASSWORD")
host := os.Getenv("SMTP_HOST")
if username == "" || password == "" || host == "" {
port := os.Getenv("SMTP_PORT")
if username == "" || password == "" || host == "" || port == "" {
logger.Warningf("smtp not configured, no emails will be sent")
smtpConfigured = false
return nil