Skip to content

Commit

Permalink
fix(core): Same version of merge node behaves differently after n8n u…
Browse files Browse the repository at this point in the history
…pdate (#13106)

Co-authored-by: कारतोफ्फेलस्क्रिप्ट™ <aditya@netroy.in>
  • Loading branch information
ShireenMissi and netroy authored Feb 10, 2025
1 parent a4c5334 commit df8f059
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/core/src/execution-engine/workflow-execute.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1489,7 +1489,7 @@ export class WorkflowExecute {

nodeSuccessData = runNodeData.data;

const didContinueOnFail = nodeSuccessData?.at(0)?.at(0)?.json?.error !== undefined;
const didContinueOnFail = nodeSuccessData?.[0]?.[0]?.json.error !== undefined;

while (didContinueOnFail && tryIndex !== maxTries - 1) {
await sleep(waitBetweenTries);
Expand Down Expand Up @@ -1531,7 +1531,7 @@ export class WorkflowExecute {

nodeSuccessData = this.assignPairedItems(nodeSuccessData, executionData);

if (nodeSuccessData === null || nodeSuccessData[0][0] === undefined) {
if (!nodeSuccessData?.[0]?.[0]) {
if (executionData.node.alwaysOutputData === true) {
const pairedItem: IPairedItemData[] = [];

Expand All @@ -1548,7 +1548,7 @@ export class WorkflowExecute {
});
});

nodeSuccessData = nodeSuccessData || [];
nodeSuccessData ??= [];
nodeSuccessData[0] = [
{
json: {},
Expand Down

0 comments on commit df8f059

Please sign in to comment.