mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 10:02:05 +00:00
feat(Send Email Node): Add an option to customize client host-name on SMTP connections (#9322)
This commit is contained in:
committed by
GitHub
parent
491c6ec546
commit
d0d52def8f
@@ -41,5 +41,13 @@ export class Smtp implements ICredentialType {
|
|||||||
type: 'boolean',
|
type: 'boolean',
|
||||||
default: true,
|
default: true,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
displayName: 'Client Host Name',
|
||||||
|
name: 'hostName',
|
||||||
|
type: 'string',
|
||||||
|
default: '',
|
||||||
|
placeholder: '',
|
||||||
|
description: 'The hostname of the client, used for identifying to the server',
|
||||||
|
},
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -210,6 +210,10 @@ function configureTransport(credentials: IDataObject, options: EmailSendOptions)
|
|||||||
secure: credentials.secure as boolean,
|
secure: credentials.secure as boolean,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
if (typeof credentials.hostName === 'string' && credentials.hostName) {
|
||||||
|
connectionOptions.name = credentials.hostName;
|
||||||
|
}
|
||||||
|
|
||||||
if (credentials.user || credentials.password) {
|
if (credentials.user || credentials.password) {
|
||||||
connectionOptions.auth = {
|
connectionOptions.auth = {
|
||||||
user: credentials.user as string,
|
user: credentials.user as string,
|
||||||
|
|||||||
Reference in New Issue
Block a user