mirror of
https://github.com/n8n-io/n8n.git
synced 2025-03-05 20:50:17 -08:00
Remove suffix from URL for user add operation
This commit is contained in:
parent
ebf81a887b
commit
cbeeffe805
|
@ -45,6 +45,13 @@ export async function nextCloudApiRequest(this: IHookFunctions | IExecuteFunctio
|
||||||
};
|
};
|
||||||
|
|
||||||
options.uri = `${credentials.webDavUrl}/${encodeURI(endpoint)}`;
|
options.uri = `${credentials.webDavUrl}/${encodeURI(endpoint)}`;
|
||||||
|
|
||||||
|
const resource = this.getNodeParameter('resource', 0);
|
||||||
|
const operation = this.getNodeParameter('operation', 0);
|
||||||
|
|
||||||
|
if (resource === 'user' && operation === 'add') {
|
||||||
|
options.uri = options.uri.replace('/remote.php/webdav', '');
|
||||||
|
}
|
||||||
console.log(options);
|
console.log(options);
|
||||||
return await this.helpers.request(options);
|
return await this.helpers.request(options);
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in a new issue