Skip to content

Commit

Permalink
fix(email): do not pass auth object to transport if no auth data present
Browse files Browse the repository at this point in the history
re #312
  • Loading branch information
sct committed Dec 17, 2020
1 parent fc12ab8 commit d5eb4d8
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions server/lib/notifications/agents/email.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,13 @@ class EmailAgent implements NotificationAgent {
host: emailSettings.smtpHost,
port: emailSettings.smtpPort,
secure: emailSettings.secure,
auth: {
user: emailSettings.authUser,
pass: emailSettings.authPass,
},
auth:
emailSettings.authUser && emailSettings.authPass
? {
user: emailSettings.authUser,
pass: emailSettings.authPass,
}
: undefined,
});
}

Expand Down

0 comments on commit d5eb4d8

Please sign in to comment.