refactor(core): Deprecate prepareOutputData (no-changelog) (#7091)

This commit is contained in:
कारतोफ्फेलस्क्रिप्ट™ 2023-09-05 12:59:02 +02:00 committed by GitHub
parent c04a996fb4
commit 6aa7b93473
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
241 changed files with 331 additions and 379 deletions

View file

@ -109,10 +109,8 @@ export async function initNodeTypes() {
outputs: ['main'],
properties: [],
},
async execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]> {
const items = this.getInputData();
return this.prepareOutputData(items);
async execute(this: IExecuteFunctions) {
return [this.getInputData()];
},
},
},
@ -151,7 +149,7 @@ export async function initNodeTypes() {
},
],
},
async trigger(this: ITriggerFunctions): Promise<ITriggerResponse> {
async trigger(this: ITriggerFunctions) {
const triggerTimes = this.getNodeParameter('triggerTimes') as unknown as {
item: TriggerTime[];
};
@ -312,7 +310,7 @@ export async function initNodeTypes() {
},
],
},
async execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]> {
async execute(this: IExecuteFunctions) {
const items = this.getInputData();
if (items.length === 0) {
@ -380,7 +378,7 @@ export async function initNodeTypes() {
returnData.push(newItem);
}
return this.prepareOutputData(returnData);
return [returnData];
},
},
},

View file

@ -2187,6 +2187,8 @@ const getCommonWorkflowFunctions = (
getRestApiUrl: () => additionalData.restApiUrl,
getInstanceBaseUrl: () => additionalData.instanceBaseUrl,
getTimezone: () => getTimezone(workflow, additionalData),
prepareOutputData: async (outputData) => [outputData],
});
const getRequestHelperFunctions = (
@ -2633,7 +2635,6 @@ export function getExecuteFunctions(
);
return dataProxy.getDataProxy();
},
prepareOutputData: NodeHelpers.prepareOutputData,
binaryToBuffer,
async putExecutionToWait(waitTill: Date): Promise<void> {
runExecutionData.waitTill = waitTill;
@ -3067,7 +3068,6 @@ export function getExecuteWebhookFunctions(
getAdditionalKeys(additionalData, mode, null),
),
getWebhookName: () => webhookData.webhookDescription.name,
prepareOutputData: NodeHelpers.prepareOutputData,
helpers: {
createDeferredPromise,
...getRequestHelperFunctions(workflow, node, additionalData),

View file

@ -1,6 +1,7 @@
import set from 'lodash/set';
import type {
IExecuteFunctions,
INodeExecutionData,
INodeParameters,
INodeTypeData,
@ -9,8 +10,6 @@ import type {
} from 'n8n-workflow';
import { deepCopy } from 'n8n-workflow';
import type { IExecuteFunctions } from '@/Interfaces';
export const predefinedNodesTypes: INodeTypeData = {
'n8n-nodes-base.if': {
sourcePath: '',
@ -241,7 +240,7 @@ export const predefinedNodesTypes: INodeTypeData = {
},
],
},
async execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]> {
async execute(this: IExecuteFunctions) {
const returnDataTrue: INodeExecutionData[] = [];
const returnDataFalse: INodeExecutionData[] = [];
@ -415,9 +414,7 @@ export const predefinedNodesTypes: INodeTypeData = {
},
],
},
async execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]> {
// const itemsInput2 = this.getInputData(1);
async execute(this: IExecuteFunctions) {
const returnData: INodeExecutionData[] = [];
const mode = this.getNodeParameter('mode', 0) as string;
@ -461,9 +458,8 @@ export const predefinedNodesTypes: INodeTypeData = {
outputs: ['main'],
properties: [],
},
async execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]> {
const items = this.getInputData();
return this.prepareOutputData(items);
async execute(this: IExecuteFunctions) {
return [this.getInputData()];
},
},
},
@ -507,7 +503,7 @@ export const predefinedNodesTypes: INodeTypeData = {
},
],
},
async execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]> {
async execute(this: IExecuteFunctions) {
const items = this.getInputData();
const returnData: INodeExecutionData[] = [];
@ -522,7 +518,7 @@ export const predefinedNodesTypes: INodeTypeData = {
returnData.push(newItem);
}
return this.prepareOutputData(returnData);
return [returnData];
},
},
},
@ -646,7 +642,7 @@ export const predefinedNodesTypes: INodeTypeData = {
},
],
},
async execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]> {
async execute(this: IExecuteFunctions) {
const items = this.getInputData();
if (items.length === 0) {
@ -714,7 +710,7 @@ export const predefinedNodesTypes: INodeTypeData = {
returnData.push(newItem);
}
return this.prepareOutputData(returnData);
return [returnData];
},
},
},
@ -736,9 +732,7 @@ export const predefinedNodesTypes: INodeTypeData = {
properties: [],
},
async execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]> {
const items = this.getInputData();
return this.prepareOutputData(items);
return [this.getInputData()];
},
},
},

View file

@ -114,7 +114,7 @@ export class MyNode implements INodeType {
item.json['myString'] = myString;
}
return this.prepareOutputData(items);
return [items];
}
}

View file

@ -48,6 +48,6 @@ export class ClassNameReplace implements INodeType {
item.json.myString = myString;
}
return this.prepareOutputData(items);
return [items];
}
}

View file

@ -1199,6 +1199,6 @@ export class ActiveCampaign implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -432,6 +432,6 @@ export class Affinity implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -867,6 +867,6 @@ export class AirtableV1 implements INodeType {
throw new NodeOperationError(this.getNode(), `The operation "${operation}" is not known!`);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -55,5 +55,5 @@ export async function router(this: IExecuteFunctions): Promise<INodeExecutionDat
throw error;
}
return this.prepareOutputData(returnData);
return [returnData];
}

View file

@ -460,7 +460,7 @@ export class ApiTemplateIo implements INodeType {
}
if (download) {
return this.prepareOutputData(returnData as unknown as INodeExecutionData[]);
return [returnData as unknown as INodeExecutionData[]];
}
}
} else if (resource === 'pdf') {
@ -549,7 +549,7 @@ export class ApiTemplateIo implements INodeType {
}
}
if (download) {
return this.prepareOutputData(returnData as unknown as INodeExecutionData[]);
return [returnData as unknown as INodeExecutionData[]];
}
}
}

View file

@ -362,6 +362,6 @@ export class Automizy implements INodeType {
returnData.push(...(responseData as NodeExecutionWithMetadata[]));
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -411,6 +411,6 @@ export class AwsDynamoDB implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -907,9 +907,9 @@ export class AwsS3V1 implements INodeType {
}
if (resource === 'file' && operation === 'download') {
// For file downloads the files get attached to the existing items
return this.prepareOutputData(items);
return [items];
} else {
return this.prepareOutputData(returnData);
return [returnData];
}
}
}

View file

@ -1070,9 +1070,9 @@ export class AwsS3V2 implements INodeType {
}
if (resource === 'file' && operation === 'download') {
// For file downloads the files get attached to the existing items
return this.prepareOutputData(items);
return [items];
} else {
return this.prepareOutputData(returnData);
return [returnData];
}
}
}

View file

@ -1298,6 +1298,6 @@ export class AwsSes implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -66,5 +66,5 @@ export async function get(this: IExecuteFunctions, index: number) {
),
};
return this.prepareOutputData(newItem as unknown as INodeExecutionData[]);
return [newItem as unknown as INodeExecutionData[]];
}

View file

@ -53,5 +53,5 @@ export async function download(this: IExecuteFunctions, index: number) {
),
};
return this.prepareOutputData(newItem as unknown as INodeExecutionData[]);
return [newItem as unknown as INodeExecutionData[]];
}

View file

@ -53,5 +53,5 @@ export async function download(this: IExecuteFunctions, index: number) {
),
};
return this.prepareOutputData(newItem as unknown as INodeExecutionData[]);
return [newItem as unknown as INodeExecutionData[]];
}

View file

@ -341,6 +341,6 @@ export class Baserow implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -379,6 +379,6 @@ export class Beeminder implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -218,6 +218,6 @@ export class Bitly implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -568,6 +568,6 @@ export class Bitwarden implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -526,9 +526,9 @@ export class Box implements INodeType {
if (resource === 'file' && operation === 'download') {
// For file downloads the files get attached to the existing items
return this.prepareOutputData(items);
return [items];
} else {
return this.prepareOutputData(returnData);
return [returnData];
}
}
}

View file

@ -285,7 +285,7 @@ export class Brandfetch implements INodeType {
if (operation === 'logo' && this.getNodeParameter('download', 0)) {
// For file downloads the files get attached to the existing items
return this.prepareOutputData(items);
return [items];
} else {
return [responseData];
}

View file

@ -179,6 +179,6 @@ export class Bubble implements INodeType {
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -633,6 +633,6 @@ export class Chargebee implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -149,6 +149,6 @@ export class CircleCi implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -559,6 +559,6 @@ export class CiscoWebex implements INodeType {
// }
// }
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -164,6 +164,6 @@ export class Clearbit implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -1636,6 +1636,6 @@ export class ClickUp implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -848,6 +848,6 @@ export class Clockify implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -359,7 +359,7 @@ export class Coda implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
// https://coda.io/developers/apis/v1beta1#operation/listRows
if (operation === 'getAllRows') {
@ -535,7 +535,7 @@ export class Coda implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}
if (resource === 'formula') {
@ -564,7 +564,7 @@ export class Coda implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
//https://coda.io/developers/apis/v1beta1#operation/listFormulas
if (operation === 'getAll') {
@ -597,7 +597,7 @@ export class Coda implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}
if (resource === 'control') {
@ -626,7 +626,7 @@ export class Coda implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
//https://coda.io/developers/apis/v1beta1#operation/listControls
if (operation === 'getAll') {
@ -659,7 +659,7 @@ export class Coda implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}
if (resource === 'view') {
@ -676,7 +676,7 @@ export class Coda implements INodeType {
);
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
//https://coda.io/developers/apis/v1beta1#operation/listViews
if (operation === 'getAll') {
@ -709,7 +709,7 @@ export class Coda implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
if (operation === 'getAllViewRows') {
const docId = this.getNodeParameter('docId', 0) as string;
@ -791,7 +791,7 @@ export class Coda implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
//https://coda.io/developers/apis/v1beta1#operation/pushViewButton
if (operation === 'pushViewButton') {
@ -820,7 +820,7 @@ export class Coda implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
if (operation === 'getAllViewColumns') {
for (let i = 0; i < items.length; i++) {
@ -853,7 +853,7 @@ export class Coda implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
//https://coda.io/developers/apis/v1beta1#operation/updateViewRow
if (operation === 'updateViewRow') {

View file

@ -142,7 +142,7 @@ export class Code implements INodeType {
standardizeOutput(item.json);
}
return this.prepareOutputData(items);
return [items];
}
// ----------------------------------
@ -172,6 +172,6 @@ export class Code implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -485,6 +485,6 @@ export class CoinGecko implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -321,6 +321,6 @@ export class Compression implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -370,6 +370,6 @@ export class Contentful implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -492,6 +492,6 @@ export class ConvertKit implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -633,6 +633,6 @@ export class Copper implements INodeType {
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -387,6 +387,6 @@ export class CrateDb implements INodeType {
// Close the connection
pgp.end();
return this.prepareOutputData(returnItems);
return [returnItems];
}
}

View file

@ -552,6 +552,6 @@ export class Crypto implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -585,6 +585,6 @@ export class DateTimeV1 implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -213,6 +213,6 @@ export class DateTimeV2 implements INodeType {
// Reset responseData
responseData.length = 0;
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -369,6 +369,6 @@ export class DebugHelper implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -270,6 +270,6 @@ export class Discord implements INodeType {
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -436,6 +436,6 @@ export class Discourse implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -761,6 +761,6 @@ export class Disqus implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -1017,10 +1017,10 @@ export class Dropbox implements INodeType {
if (resource === 'file' && operation === 'download') {
// For file downloads the files get attached to the existing items
return this.prepareOutputData(items);
return [items];
} else {
// For all other ones does the output items get replaced
return this.prepareOutputData(returnData);
return [returnData];
}
}
}

View file

@ -370,6 +370,6 @@ export class Dropcontact implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -202,6 +202,6 @@ export class E2eTest implements INodeType {
};
async execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]> {
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -288,6 +288,6 @@ export class ERPNext implements INodeType {
);
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -1325,6 +1325,6 @@ export class EditImage implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -753,6 +753,6 @@ export class Egoi implements INodeType {
);
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -590,6 +590,6 @@ export class ElasticSecurity implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -349,6 +349,6 @@ export class Elasticsearch implements INodeType {
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -241,6 +241,6 @@ export class EmailSendV1 implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -267,5 +267,5 @@ export async function execute(this: IExecuteFunctions): Promise<INodeExecutionDa
}
}
return this.prepareOutputData(returnData);
return [returnData];
}

View file

@ -441,6 +441,6 @@ export class Emelia implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -74,6 +74,6 @@ export class ErrorTrigger implements INodeType {
};
}
return this.prepareOutputData(items);
return [items];
}
}

View file

@ -127,6 +127,6 @@ export class ExecuteCommand implements INodeType {
}
}
return this.prepareOutputData(returnItems);
return [returnItems];
}
}

View file

@ -208,7 +208,7 @@ export class ExecuteWorkflow implements INodeType {
return receivedData;
} catch (error) {
if (this.continueOnFail()) {
return this.prepareOutputData([{ json: { error: error.message } }]);
return [[{ json: { error: error.message } }]];
}
throw error;

View file

@ -1,9 +1,4 @@
import type {
IExecuteFunctions,
INodeExecutionData,
INodeType,
INodeTypeDescription,
} from 'n8n-workflow';
import type { IExecuteFunctions, INodeType, INodeTypeDescription } from 'n8n-workflow';
export class ExecuteWorkflowTrigger implements INodeType {
description: INodeTypeDescription = {
@ -49,9 +44,7 @@ export class ExecuteWorkflowTrigger implements INodeType {
],
};
async execute(this: IExecuteFunctions): Promise<INodeExecutionData[][]> {
const items = this.getInputData();
return this.prepareOutputData(items);
async execute(this: IExecuteFunctions) {
return [this.getInputData()];
}
}

View file

@ -843,6 +843,6 @@ export class FileMaker implements INodeType {
}
await logout.call(this, token as string);
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -269,6 +269,6 @@ export class Flow implements INodeType {
);
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -1420,6 +1420,6 @@ export class Freshdesk implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -1390,6 +1390,6 @@ export class Freshservice implements INodeType {
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -994,6 +994,6 @@ export class FreshworksCrm implements INodeType {
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -806,7 +806,7 @@ export class Ftp implements INodeType {
}
} catch (error) {
if (this.continueOnFail()) {
return this.prepareOutputData([{ json: { error: error.message } }]);
return [[{ json: { error: error.message } }]];
}
throw error;

View file

@ -224,6 +224,6 @@ return items;`,
}
}
return this.prepareOutputData(items);
return [items];
}
}

View file

@ -240,6 +240,6 @@ return item;`,
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -308,6 +308,6 @@ export class GetResponse implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -359,6 +359,6 @@ export class Ghost implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -500,6 +500,6 @@ export class Git implements INodeType {
}
}
return this.prepareOutputData(returnItems);
return [returnItems];
}
}

View file

@ -2269,7 +2269,7 @@ export class Github implements INodeType {
overwriteDataOperationsArray.includes(fullOperation)
) {
// Return data gets replaced
return this.prepareOutputData(returnData);
return [returnData];
} else {
// For all other ones simply return the unchanged items
return [items];

View file

@ -1766,10 +1766,10 @@ export class Gitlab implements INodeType {
overwriteDataOperationsArray.includes(fullOperation)
) {
// Return data gets replaced
return this.prepareOutputData(returnData);
return [returnData];
} else {
// For all other ones simply return the unchanged items
return this.prepareOutputData(items);
return [items];
}
}
}

View file

@ -652,6 +652,6 @@ export class GoToWebinar implements INodeType {
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -302,6 +302,6 @@ export class GoogleAnalyticsV1 implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -47,5 +47,5 @@ export async function router(this: IExecuteFunctions): Promise<INodeExecutionDat
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}

View file

@ -301,6 +301,6 @@ export class GoogleBigQueryV1 implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -23,5 +23,5 @@ export async function router(this: IExecuteFunctions): Promise<INodeExecutionDat
throw new NodeOperationError(this.getNode(), `The resource "${resource}" is not known`);
}
return this.prepareOutputData(returnData);
return [returnData];
}

View file

@ -522,6 +522,6 @@ export class GoogleBooks implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -602,6 +602,6 @@ export class GoogleCalendar implements INodeType {
}
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -559,10 +559,10 @@ export class GoogleChat implements INodeType {
if (operation === 'download') {
// For file downloads the files get attached to the existing items
return this.prepareOutputData(items);
return [items];
} else {
// For all other ones does the output get replaced
return this.prepareOutputData(returnData);
return [returnData];
}
}
}

View file

@ -521,6 +521,6 @@ export class GoogleContacts implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -528,6 +528,6 @@ export class GoogleDocs implements INodeType {
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -2736,10 +2736,10 @@ export class GoogleDriveV1 implements INodeType {
}
if (resource === 'file' && operation === 'download') {
// For file downloads the files get attached to the existing items
return this.prepareOutputData(items);
return [items];
} else {
// For all other ones does the output items get replaced
return this.prepareOutputData(returnData);
return [returnData];
}
}
}

View file

@ -51,5 +51,5 @@ export async function router(this: IExecuteFunctions): Promise<INodeExecutionDat
}
}
return this.prepareOutputData(returnData);
return [returnData];
}

View file

@ -402,6 +402,6 @@ export class GoogleFirebaseCloudFirestore implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -249,6 +249,6 @@ export class GoogleFirebaseRealtimeDatabase implements INodeType {
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -424,6 +424,6 @@ export class GSuiteAdmin implements INodeType {
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -834,6 +834,6 @@ export class GmailV1 implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -819,8 +819,8 @@ export class GmailV2 implements INodeType {
['draft', 'message', 'thread'].includes(resource) &&
['get', 'getAll'].includes(operation)
) {
return this.prepareOutputData(unescapeSnippets(returnData));
return [unescapeSnippets(returnData)];
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -282,6 +282,6 @@ export class GooglePerspective implements INodeType {
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -141,10 +141,10 @@ export class GoogleSheetsV1 implements INodeType {
// TODO: Should add this data somewhere
// TODO: Should have something like add metadata which does not get passed through
return await this.prepareOutputData(items);
return [items];
} catch (error) {
if (this.continueOnFail()) {
return this.prepareOutputData([{ json: { error: error.message } }]);
return [[{ json: { error: error.message } }]];
}
throw error;
}
@ -156,10 +156,10 @@ export class GoogleSheetsV1 implements INodeType {
await sheet.clearData(sheet.encodeRange(range));
const items = this.getInputData();
return await this.prepareOutputData(items);
return [items];
} catch (error) {
if (this.continueOnFail()) {
return this.prepareOutputData([{ json: { error: error.message } }]);
return [[{ json: { error: error.message } }]];
}
throw error;
}
@ -245,10 +245,10 @@ export class GoogleSheetsV1 implements INodeType {
await sheet.spreadsheetBatchUpdate(requests);
const items = this.getInputData();
return await this.prepareOutputData(items);
return [items];
} catch (error) {
if (this.continueOnFail()) {
return this.prepareOutputData([{ json: { error: error.message } }]);
return [[{ json: { error: error.message } }]];
}
throw error;
}
@ -420,10 +420,10 @@ export class GoogleSheetsV1 implements INodeType {
// TODO: Should add this data somewhere
// TODO: Should have something like add metadata which does not get passed through
return await this.prepareOutputData(items);
return [items];
} catch (error) {
if (this.continueOnFail()) {
return this.prepareOutputData([{ json: { error: error.message } }]);
return [[{ json: { error: error.message } }]];
}
throw error;
}

View file

@ -591,6 +591,6 @@ export class GoogleSlides implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -271,6 +271,6 @@ export class GoogleTasks implements INodeType {
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -212,6 +212,6 @@ export class GoogleTranslate implements INodeType {
}
}
return this.prepareOutputData(responseData);
return [responseData];
}
}

View file

@ -1068,6 +1068,6 @@ export class YouTube implements INodeType {
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -225,6 +225,6 @@ export class Gotify implements INodeType {
throw error;
}
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

View file

@ -523,6 +523,6 @@ export class GraphQL implements INodeType {
}
}
return this.prepareOutputData(returnItems);
return [returnItems];
}
}

View file

@ -263,6 +263,6 @@ export class Grist implements INodeType {
returnData.push(...executionData);
}
return this.prepareOutputData(returnData);
return [returnData];
}
}

Some files were not shown because too many files have changed in this diff Show more