mirror of
https://github.com/Unleash/unleash.git
synced 2025-01-25 00:07:47 +01:00
Revert "fix: uri encode smtp connection string (#901)"
This reverts commit 8f1a5f5a64
.
This commit is contained in:
parent
1d9df2917d
commit
bb9ae03b27
@ -2,7 +2,6 @@ import { createTransport, Transporter } from 'nodemailer';
|
||||
import Mustache from 'mustache';
|
||||
import path from 'path';
|
||||
import { readFileSync, existsSync } from 'fs';
|
||||
import { escape } from 'querystring';
|
||||
import { Logger, LogProvider } from '../logger';
|
||||
import NotFoundError from '../error/notfound-error';
|
||||
import { IEmailOption } from '../types/option';
|
||||
@ -58,9 +57,7 @@ export class EmailService {
|
||||
if (email.host === 'test') {
|
||||
this.mailer = createTransport({ jsonTransport: true });
|
||||
} else {
|
||||
const connectionString = escape(
|
||||
`${email.smtpuser}:${email.smtppass}@${email.host}:${email.port}`,
|
||||
);
|
||||
const connectionString = `${email.smtpuser}:${email.smtppass}@${email.host}:${email.port}`;
|
||||
this.mailer = email.secure
|
||||
? createTransport(`smtps://${connectionString}`)
|
||||
: createTransport(`smtp://${connectionString}`);
|
||||
|
Loading…
Reference in New Issue
Block a user