mirror of
https://github.com/IT4Change/Ocelot-Social.git
synced 2025-12-13 07:45:56 +00:00
SMTP_SECURE option
This commit is contained in:
parent
28dd310aa1
commit
8e2d8a77c3
@ -40,7 +40,8 @@ const server = {
|
||||
const smtp = {
|
||||
SMTP_HOST: env.SMTP_HOST,
|
||||
SMTP_PORT: env.SMTP_PORT,
|
||||
SMTP_IGNORE_TLS: env.SMTP_IGNORE_TLS || true,
|
||||
SMTP_IGNORE_TLS: env.SMTP_IGNORE_TLS === 'true' || true,
|
||||
SMTP_SECURE: env.SMTP_IGNORE_TLS === 'true' || false,
|
||||
SMTP_USERNAME: env.SMTP_USERNAME,
|
||||
SMTP_PASSWORD: env.SMTP_PASSWORD,
|
||||
}
|
||||
|
||||
@ -22,8 +22,8 @@ if (!hasEmailConfig) {
|
||||
const transporter = nodemailer.createTransport({
|
||||
host: CONFIG.SMTP_HOST,
|
||||
port: CONFIG.SMTP_PORT,
|
||||
ignoreTLS: CONFIG.SMTP_IGNORE_TLS === 'true',
|
||||
secure: false, // true for 465, false for other ports
|
||||
ignoreTLS: CONFIG.SMTP_IGNORE_TLS,
|
||||
secure: CONFIG.SMTP_SECURE, // true for 465, false for other ports
|
||||
auth: hasAuthData && {
|
||||
user: CONFIG.SMTP_USERNAME,
|
||||
pass: CONFIG.SMTP_PASSWORD,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user