mirror of
https://github.com/n8n-io/n8n.git
synced 2025-01-13 05:47:31 -08:00
🔀 Merge pull request #202 from RicardoE105/fix/rocketchat-node
fixed issue with url
This commit is contained in:
commit
2f80b38762
|
@ -20,14 +20,12 @@ export async function rocketchatApiRequest(this: IHookFunctions | IExecuteFuncti
|
||||||
headers: headerWithAuthentication,
|
headers: headerWithAuthentication,
|
||||||
method,
|
method,
|
||||||
body,
|
body,
|
||||||
uri: `${credentials.domain}${resource}.${operation}`,
|
uri: `${credentials.domain}/api/v1${resource}.${operation}`,
|
||||||
json: true
|
json: true
|
||||||
};
|
};
|
||||||
|
|
||||||
if (Object.keys(options.body).length === 0) {
|
if (Object.keys(options.body).length === 0) {
|
||||||
delete options.body;
|
delete options.body;
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
return await this.helpers.request!(options);
|
return await this.helpers.request!(options);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
|
Loading…
Reference in a new issue