fix(Email Trigger (IMAP) Node): Fix connection issue with unexpected spaces in host (#6886)

This commit is contained in:
Jon
2023-08-10 08:58:51 +01:00
committed by GitHub
parent 718e61354d
commit f3248e46e4
2 changed files with 16 additions and 16 deletions

View File

@@ -241,7 +241,7 @@ export class EmailReadImapV1 implements INodeType {
imap: {
user: credentials.user as string,
password: credentials.password as string,
host: credentials.host as string,
host: (credentials.host as string).trim(),
port: credentials.port as number,
tls: credentials.secure as boolean,
authTimeout: 20000,
@@ -250,7 +250,7 @@ export class EmailReadImapV1 implements INodeType {
const tlsOptions: IDataObject = {};
if (credentials.secure) {
tlsOptions.servername = credentials.host as string;
tlsOptions.servername = (credentials.host as string).trim();
}
if (!isEmpty(tlsOptions)) {
config.imap.tlsOptions = tlsOptions;
@@ -527,7 +527,7 @@ export class EmailReadImapV1 implements INodeType {
imap: {
user: credentials.user as string,
password: credentials.password as string,
host: credentials.host as string,
host: (credentials.host as string).trim(),
port: credentials.port as number,
tls: credentials.secure as boolean,
authTimeout: 20000,
@@ -579,7 +579,7 @@ export class EmailReadImapV1 implements INodeType {
}
if (credentials.secure) {
tlsOptions.servername = credentials.host as string;
tlsOptions.servername = (credentials.host as string).trim();
}
if (!isEmpty(tlsOptions)) {