fix: Manually reverted PR 11716 Do not assign all paired items (no-changelog) (#13429)

This commit is contained in:
Shireen Missi
2025-02-21 19:38:35 +00:00
committed by GitHub
parent c3f111275b
commit 2ef6f111d0
34 changed files with 243 additions and 55 deletions

View File

@@ -16,6 +16,7 @@ import { oldVersionNotice } from '@utils/descriptions';
import { googleApiRequest, googleApiRequestAllItems, simplify } from './GenericFunctions';
import { recordFields, recordOperations } from './RecordDescription';
import { generatePairedItemData } from '../../../../utils/utilities';
const versionDescription: INodeTypeDescription = {
displayName: 'Google BigQuery',
@@ -194,6 +195,8 @@ export class GoogleBigQueryV1 implements INodeType {
body.rows = rows;
const itemData = generatePairedItemData(items.length);
try {
responseData = await googleApiRequest.call(
this,
@@ -202,11 +205,17 @@ export class GoogleBigQueryV1 implements INodeType {
body,
);
const executionData = this.helpers.returnJsonArray(responseData as IDataObject[]);
const executionData = this.helpers.constructExecutionMetaData(
this.helpers.returnJsonArray(responseData as IDataObject[]),
{ itemData },
);
returnData.push(...executionData);
} catch (error) {
if (this.continueOnFail()) {
const executionErrorData = this.helpers.returnJsonArray({ error: error.message });
const executionErrorData = this.helpers.constructExecutionMetaData(
this.helpers.returnJsonArray({ error: error.message }),
{ itemData },
);
returnData.push(...executionErrorData);
}
throw new NodeApiError(this.getNode(), error as JsonObject, { itemIndex: 0 });