fix(core)!: $(...).[last,first,all]() defaulting to the first output instead of the output that connects the nodes (#9760)

This commit is contained in:
Danny Martini
2024-06-19 15:10:30 +02:00
committed by GitHub
parent 77bf16667b
commit 4ac9266820
5 changed files with 244 additions and 14 deletions

View File

@@ -0,0 +1,84 @@
{
"data": {
"startData": {},
"resultData": {
"runData": {
"When clicking Test workflow": [
{
"hints": [],
"startTime": 1718369813697,
"executionTime": 0,
"source": [],
"executionStatus": "success",
"data": {
"main": [
[
{
"json": {
"name": "First item",
"code": 1
},
"pairedItem": {
"item": 0
}
},
{
"json": {
"name": "Second item",
"code": 2
},
"pairedItem": {
"item": 0
}
}
]
]
}
}
],
"If": [
{
"hints": [],
"startTime": 1718369813698,
"executionTime": 1,
"source": [
{
"previousNode": "When clicking Test workflow"
}
],
"executionStatus": "success",
"data": {
"main": [
[],
[
{
"json": {
"name": "First item",
"code": 1
},
"pairedItem": {
"item": 0
}
},
{
"json": {
"name": "Second item",
"code": 2
},
"pairedItem": {
"item": 1
}
}
]
]
}
}
]
}
}
},
"mode": "manual",
"startedAt": "2024-02-08T15:45:18.848Z",
"stoppedAt": "2024-02-08T15:45:18.862Z",
"status": "running"
}

View File

@@ -0,0 +1,84 @@
{
"meta": {
"instanceId": "060d2be233778dc6349e0f3fa8d972652e8dff467638325ffc56812c6b66ef1a"
},
"nodes": [
{
"parameters": {},
"id": "656d6d8d-1af6-4af7-ab53-7c4e495ee51c",
"name": "When clicking Test workflow",
"type": "n8n-nodes-base.manualTrigger",
"typeVersion": 1,
"position": [-300, 1880]
},
{
"parameters": {
"conditions": {
"options": {
"caseSensitive": true,
"leftValue": "",
"typeValidation": "strict"
},
"conditions": [
{
"id": "1fff886f-3d13-4fbf-b0fb-7e2f845937c0",
"leftValue": "={{ false }}",
"rightValue": "",
"operator": {
"type": "boolean",
"operation": "true",
"singleValue": true
}
}
],
"combinator": "and"
},
"options": {}
},
"id": "204feab7-f5e9-458f-8fdb-4b762b184147",
"name": "If",
"type": "n8n-nodes-base.if",
"typeVersion": 2,
"position": [40, 1880]
},
{
"parameters": {
"assignments": {
"assignments": []
},
"options": {}
},
"id": "ab122060-f8da-475e-b6c6-d9e486289e1f",
"name": "Edit Fields",
"type": "n8n-nodes-base.set",
"typeVersion": 3.3,
"position": [360, 2080]
}
],
"connections": {
"When clicking Test workflow": {
"main": [
[
{
"node": "If",
"type": "main",
"index": 0
}
]
]
},
"If": {
"main": [
[],
[
{
"node": "Edit Fields",
"type": "main",
"index": 0
}
]
]
}
},
"pinData": {}
}