feat: auto detect secure port for email transport
This commit is contained in:
parent
da59f11bcc
commit
776004b5be
1 changed files with 1 additions and 1 deletions
|
|
@ -47,7 +47,7 @@ export class verificationController extends Controller {
|
||||||
emailTransport = nodemailer.createTransport({
|
emailTransport = nodemailer.createTransport({
|
||||||
host: process.env.SMTP_HOST!,
|
host: process.env.SMTP_HOST!,
|
||||||
port: +process.env.SMTP_PORT!,
|
port: +process.env.SMTP_PORT!,
|
||||||
secure: false, // true for port 465, false for other ports
|
secure: +process.env.SMTP_PORT! === 465, // true for port 465, false for other ports
|
||||||
auth: {
|
auth: {
|
||||||
user: process.env.SMTP_USER!,
|
user: process.env.SMTP_USER!,
|
||||||
pass: process.env.SMTP_PASS!,
|
pass: process.env.SMTP_PASS!,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue