mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 10:02:05 +00:00
fix(core): Update packages to address CVE-2023-2142 and CVE-2020-28469 (#6844)
GH Advisories: [ CVE-2023-2142](https://github.com/advisories/GHSA-x77j-w7wf-fjmw) [CVE-2020-28469](https://github.com/advisories/GHSA-ww39-953v-wcq6) --------- Co-authored-by: Marcus <marcus@n8n.io>
This commit is contained in:
committed by
GitHub
parent
6ec7033bb7
commit
a5667e6c42
@@ -9,7 +9,7 @@ import type {
|
||||
INodeTypeDescription,
|
||||
} from 'n8n-workflow';
|
||||
|
||||
import mqtt from 'mqtt';
|
||||
import * as mqtt from 'mqtt';
|
||||
|
||||
export class Mqtt implements INodeType {
|
||||
description: INodeTypeDescription = {
|
||||
@@ -155,7 +155,7 @@ export class Mqtt implements INodeType {
|
||||
client = mqtt.connect(brokerUrl, clientOptions);
|
||||
}
|
||||
|
||||
await new Promise((resolve, reject): any => {
|
||||
await new Promise((resolve, reject) => {
|
||||
client.on('connect', (test) => {
|
||||
resolve(test);
|
||||
client.end();
|
||||
@@ -168,7 +168,7 @@ export class Mqtt implements INodeType {
|
||||
} catch (error) {
|
||||
return {
|
||||
status: 'Error',
|
||||
message: error.message,
|
||||
message: (error as Error).message,
|
||||
};
|
||||
}
|
||||
return {
|
||||
@@ -232,7 +232,7 @@ export class Mqtt implements INodeType {
|
||||
|
||||
const sendInputData = this.getNodeParameter('sendInputData', 0) as boolean;
|
||||
|
||||
const data = await new Promise((resolve, reject): any => {
|
||||
const data = await new Promise((resolve, reject) => {
|
||||
client.on('connect', () => {
|
||||
for (let i = 0; i < length; i++) {
|
||||
let message;
|
||||
@@ -256,7 +256,7 @@ export class Mqtt implements INodeType {
|
||||
resolve([items]);
|
||||
});
|
||||
|
||||
client.on('error', (e: string | undefined) => {
|
||||
client.on('error', (e) => {
|
||||
reject(e);
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user