mirror of
https://github.com/n8n-io/n8n.git
synced 2025-03-05 20:50:17 -08:00
⚡ Small change to #2305
This commit is contained in:
parent
431f58a5ee
commit
c888b0512a
|
@ -209,11 +209,11 @@ export class MicrosoftOneDrive implements INodeType {
|
||||||
if (resource === 'folder') {
|
if (resource === 'folder') {
|
||||||
//https://docs.microsoft.com/en-us/onedrive/developer/rest-api/api/driveitem_post_children?view=odsp-graph-online
|
//https://docs.microsoft.com/en-us/onedrive/developer/rest-api/api/driveitem_post_children?view=odsp-graph-online
|
||||||
if (operation === 'create') {
|
if (operation === 'create') {
|
||||||
const names = (this.getNodeParameter('name', i) as string).split("/").filter( s => s.trim() != "" );
|
const names = (this.getNodeParameter('name', i) as string).split('/').filter(s => s.trim() !== '');
|
||||||
const options = this.getNodeParameter('options', i) as IDataObject;
|
const options = this.getNodeParameter('options', i) as IDataObject;
|
||||||
let parentFolderId = options.parentFolderId ? options.parentFolderId : null;
|
let parentFolderId = options.parentFolderId ? options.parentFolderId : null;
|
||||||
for( let name of names ) {
|
for (const name of names) {
|
||||||
let body: IDataObject = {
|
const body: IDataObject = {
|
||||||
name,
|
name,
|
||||||
folder: {},
|
folder: {},
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in a new issue