refactor(core): fixes n8n-local-rules/no-json-parse-json-stringify warnings (#4407)

* 🔨 fixes

* 🔨 set rule to error
This commit is contained in:
Michael Kret
2022-10-21 18:24:58 +03:00
committed by GitHub
parent e10128cbea
commit 9d6a2c32d7
21 changed files with 75 additions and 50 deletions

View File

@@ -4,6 +4,7 @@ import { get } from 'lodash';
import { IExecuteFunctions } from 'n8n-core';
import {
deepCopy,
GenericValue,
INodeExecutionData,
INodeType,
@@ -427,7 +428,7 @@ export class MergeV1 implements INodeType {
continue;
} else if (mode === 'mergeByKey') {
// Copy the entry as the data gets changed
entry = JSON.parse(JSON.stringify(entry));
entry = deepCopy(entry);
for (key of Object.keys(copyData[referenceValue as string].json)) {
if (key === propertyName2) {