mirror of
https://github.com/dawidd6/action-send-mail.git
synced 2026-10-19 14:04:32 +07:00
node_modules: update (#349)
Co-authored-by: dawidd6 <9713907+dawidd6@users.noreply.github.com>
This commit is contained in:
1 parent
9d0c26ec8b
commit
0a1f5db16c
36 files changed
+1934
-648
No files matched your search
+12
-1
@@ -5,6 +5,13 @@ import * as shared from '../shared/index.js';
|
||||
import XOAuth2 from '../xoauth2/index.js';
|
||||
import * as errors from '../errors.js';
|
||||
import * as packageData from '../package-info.js';
|
||||
// The keys a message's `auth` may set on top of the transport's auth settings: the ones that
|
||||
// say who logs in and with what. Everything else in the auth block (accessUrl, clientId,
|
||||
// clientSecret, customHeaders, customParams, tls, privateKey, serviceClient and the rest)
|
||||
// names the endpoint the credentials go to or is a secret of the application itself, and
|
||||
// a message that could set `auth.accessUrl` and force a refresh would have the transport's
|
||||
// client secret and refresh token posted to a URL of its choosing
|
||||
const MESSAGE_AUTH_KEYS = ['type', 'user', 'pass', 'accessToken', 'refreshToken', 'expires'];
|
||||
/**
|
||||
* Creates a SMTP transport object for Nodemailer
|
||||
*
|
||||
@@ -64,7 +71,11 @@ class SMTPTransport extends EventEmitter {
|
||||
}
|
||||
return this.auth;
|
||||
}
|
||||
const authData = Object.assign({}, this.options.auth && typeof this.options.auth === 'object' ? this.options.auth : {}, typeof authOpts === 'object' ? authOpts : {});
|
||||
const authData = Object.assign({}, this.options.auth && typeof this.options.auth === 'object' ? this.options.auth : {});
|
||||
if (typeof authOpts === 'object') {
|
||||
// see MESSAGE_AUTH_KEYS
|
||||
shared.copyOwnKeys(authData, authOpts, key => !MESSAGE_AUTH_KEYS.includes(key));
|
||||
}
|
||||
if (Object.keys(authData).length === 0) {
|
||||
return false;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user