@pokash/n8n-nodes-optima-rest-api 1.4.0 → 1.5.0

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.
@@ -736,7 +736,22 @@ class OptimaRestApi {
736
736
  }
737
737
  else {
738
738
  // Split mode - return each customer as separate item
739
- if (items[i].binary) {
739
+ if (customers.length === 0) {
740
+ // No customers found - return metadata so flow can continue
741
+ const result = {
742
+ json: {
743
+ Success: responseData.Success,
744
+ TotalCount: responseData.TotalCount,
745
+ Customers: [],
746
+ _empty: true,
747
+ }
748
+ };
749
+ if (items[i].binary) {
750
+ result.binary = items[i].binary;
751
+ }
752
+ returnData.push(result);
753
+ }
754
+ else if (items[i].binary) {
740
755
  // First item gets binary
741
756
  returnData.push({
742
757
  json: customers[0] || {},
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@pokash/n8n-nodes-optima-rest-api",
3
- "version": "1.4.0",
3
+ "version": "1.5.0",
4
4
  "description": "n8n node for Comarch Optima REST API integration",
5
5
  "keywords": [
6
6
  "n8n-community-node-package",