mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-18 02:21:13 +00:00
refactor(core): fix for no-uncaught-json-parse warnings
This commit is contained in:
@@ -4,6 +4,7 @@ import {
|
||||
IN8nHttpFullResponse,
|
||||
INodeExecutionData,
|
||||
INodeProperties,
|
||||
jsonParse,
|
||||
} from 'n8n-workflow';
|
||||
|
||||
export const questionsOperations: INodeProperties[] = [
|
||||
@@ -74,9 +75,7 @@ export const questionsOperations: INodeProperties[] = [
|
||||
}
|
||||
items[i] = newItem;
|
||||
if (this.getNode().parameters.format === 'json') {
|
||||
items[i].json = JSON.parse(
|
||||
items[i].json as unknown as string,
|
||||
)[0] as unknown as IDataObject;
|
||||
items[i].json = jsonParse<IDataObject[]>(items[i].json as unknown as string)[0];
|
||||
console.log(items[i].json);
|
||||
delete items[i].binary;
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user