n8n-nodes-crewai 0.2.21 → 0.2.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -71,18 +71,24 @@ class CrewaiExecute {
71
71
  const inputText = this.getNodeParameter('inputText', 0);
72
72
  const processType = this.getNodeParameter('processType', 0);
73
73
  const agentsAndTasks = [];
74
- // Processar todos os inputs dinamicamente
74
+ // Processar todos os inputs dinamicamente com append mode
75
75
  for (let inputIndex = 0; inputIndex < numberInputs; inputIndex++) {
76
- const items = this.getInputData(inputIndex);
76
+ let items;
77
+ try {
78
+ items = this.getInputData(inputIndex);
79
+ }
80
+ catch {
81
+ // Input não conectado, continue
82
+ continue;
83
+ }
77
84
  if (!items || items.length === 0) {
78
85
  continue;
79
86
  }
87
+ // Append: adiciona TODOS os itens de cada input
80
88
  for (const item of items) {
81
- // Pular itens vazios ou que não tenham a estrutura esperada
82
89
  if (!item.json || Object.keys(item.json).length === 0) {
83
90
  continue;
84
91
  }
85
- // Adiciona o item completo (pode ter agent+tasks ou outros dados)
86
92
  agentsAndTasks.push(item.json);
87
93
  }
88
94
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "n8n-nodes-crewai",
3
- "version": "0.2.21",
3
+ "version": "0.2.22",
4
4
  "description": "Community nodes for CrewAI integration",
5
5
  "license": "MIT",
6
6
  "author": {