n8n-nodes-onedrive-business 1.1.4 → 1.1.7

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.
@@ -253,8 +253,8 @@ class OneDriveBusiness {
253
253
  },
254
254
  default: '',
255
255
  required: true,
256
- placeholder: '/Documents/file.pdf',
257
- description: 'Destination path in OneDrive (including filename)',
256
+ placeholder: '/Documents/NewFolder/{{ $binary.data.fileName }}',
257
+ description: 'Full path of the file to save (e.g. /Documents/report.pdf). Tip: Use Expression to keep original name: /Path/To/Folder/{{ $binary.data.fileName }}',
258
258
  },
259
259
  {
260
260
  displayName: 'Binary Property',
@@ -378,7 +378,7 @@ class OneDriveBusinessTrigger {
378
378
  },
379
379
  })));
380
380
  }
381
- return workflowData;
381
+ return workflowData.length > 0 ? workflowData : null;
382
382
  }
383
383
  }
384
384
  exports.OneDriveBusinessTrigger = OneDriveBusinessTrigger;
@@ -76,7 +76,10 @@ function buildItemPath(drivePath, itemPath, itemId) {
76
76
  return `${drivePath}/items/${itemId}`;
77
77
  }
78
78
  if (itemPath) {
79
- const sanitized = sanitizePath(itemPath);
79
+ // Strip standard Graph API prefixes if present
80
+ // Matches: /drive/root:, drive/root:, /drives/{id}/root:, drives/{id}/root:
81
+ let cleanPath = itemPath.replace(/^(\/)?(drive|drives\/[^\/]+)\/root:/i, '');
82
+ const sanitized = sanitizePath(cleanPath);
80
83
  if (sanitized) {
81
84
  return `${drivePath}/root:/${sanitized}`;
82
85
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "n8n-nodes-onedrive-business",
3
- "version": "1.1.4",
3
+ "version": "1.1.7",
4
4
  "description": "n8n custom node for OneDrive Business with robust deduplication and webhook triggers",
5
5
  "keywords": [
6
6
  "n8n",