fix: email processor esm issue with p-throttle + config read
Signed-off-by: Heikki Hellgren <heikki.hellgren@op.fi>
This commit is contained in:
@@ -45,7 +45,7 @@
|
||||
"@backstage/types": "workspace:^",
|
||||
"lodash": "^4.17.21",
|
||||
"nodemailer": "^6.9.13",
|
||||
"p-throttle": "^6.1.0"
|
||||
"p-throttle": "^4.1.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@backstage/backend-test-utils": "workspace:^",
|
||||
|
||||
+6
-6
@@ -52,7 +52,7 @@ describe('NotificationsEmailProcessor', () => {
|
||||
notifications: {
|
||||
processors: {
|
||||
email: {
|
||||
transport: {
|
||||
transportConfig: {
|
||||
transport: 'smtp',
|
||||
hostname: 'localhost',
|
||||
port: 465,
|
||||
@@ -98,7 +98,7 @@ describe('NotificationsEmailProcessor', () => {
|
||||
notifications: {
|
||||
processors: {
|
||||
email: {
|
||||
transport: {
|
||||
transportConfig: {
|
||||
transport: 'ses',
|
||||
region: 'us-west-2',
|
||||
},
|
||||
@@ -138,7 +138,7 @@ describe('NotificationsEmailProcessor', () => {
|
||||
notifications: {
|
||||
processors: {
|
||||
email: {
|
||||
transport: {
|
||||
transportConfig: {
|
||||
transport: 'sendmail',
|
||||
path: '/usr/local/bin/sendmail',
|
||||
},
|
||||
@@ -189,7 +189,7 @@ describe('NotificationsEmailProcessor', () => {
|
||||
notifications: {
|
||||
processors: {
|
||||
email: {
|
||||
transport: {
|
||||
transportConfig: {
|
||||
transport: 'sendmail',
|
||||
path: '/usr/local/bin/sendmail',
|
||||
},
|
||||
@@ -246,7 +246,7 @@ describe('NotificationsEmailProcessor', () => {
|
||||
notifications: {
|
||||
processors: {
|
||||
email: {
|
||||
transport: {
|
||||
transportConfig: {
|
||||
transport: 'sendmail',
|
||||
path: '/usr/local/bin/sendmail',
|
||||
},
|
||||
@@ -306,7 +306,7 @@ describe('NotificationsEmailProcessor', () => {
|
||||
notifications: {
|
||||
processors: {
|
||||
email: {
|
||||
transport: {
|
||||
transportConfig: {
|
||||
transport: 'sendmail',
|
||||
path: '/usr/local/bin/sendmail',
|
||||
},
|
||||
|
||||
+1
-1
@@ -62,7 +62,7 @@ export class NotificationsEmailProcessor implements NotificationProcessor {
|
||||
const emailProcessorConfig = config.getConfig(
|
||||
'notifications.processors.email',
|
||||
);
|
||||
this.transportConfig = emailProcessorConfig.getConfig('transport');
|
||||
this.transportConfig = emailProcessorConfig.getConfig('transportConfig');
|
||||
this.broadcastConfig =
|
||||
emailProcessorConfig.getOptionalConfig('broadcastConfig');
|
||||
this.sender = emailProcessorConfig.getString('sender');
|
||||
|
||||
Reference in New Issue
Block a user