mirror of
https://github.com/n8n-io/n8n.git
synced 2025-03-05 20:50:17 -08:00
fix(Chat Trigger Node): Fix auth in "Embedded Chat" mode (#10734)
Some checks are pending
Test Master / install-and-build (push) Waiting to run
Test Master / Unit tests (18.x) (push) Blocked by required conditions
Test Master / Unit tests (20.x) (push) Blocked by required conditions
Test Master / Unit tests (22.4) (push) Blocked by required conditions
Test Master / Lint (push) Blocked by required conditions
Test Master / Notify Slack on failure (push) Blocked by required conditions
Some checks are pending
Test Master / install-and-build (push) Waiting to run
Test Master / Unit tests (18.x) (push) Blocked by required conditions
Test Master / Unit tests (20.x) (push) Blocked by required conditions
Test Master / Unit tests (22.4) (push) Blocked by required conditions
Test Master / Lint (push) Blocked by required conditions
Test Master / Notify Slack on failure (push) Blocked by required conditions
This commit is contained in:
parent
d3861b31ce
commit
96db501a61
|
@ -460,7 +460,6 @@ export class ChatTrigger extends Node {
|
||||||
const mode = ctx.getMode() === 'manual' ? 'test' : 'production';
|
const mode = ctx.getMode() === 'manual' ? 'test' : 'production';
|
||||||
const bodyData = ctx.getBodyData() ?? {};
|
const bodyData = ctx.getBodyData() ?? {};
|
||||||
|
|
||||||
if (nodeMode === 'hostedChat') {
|
|
||||||
try {
|
try {
|
||||||
await validateAuth(ctx);
|
await validateAuth(ctx);
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
@ -473,7 +472,7 @@ export class ChatTrigger extends Node {
|
||||||
}
|
}
|
||||||
throw error;
|
throw error;
|
||||||
}
|
}
|
||||||
|
if (nodeMode === 'hostedChat') {
|
||||||
// Show the chat on GET request
|
// Show the chat on GET request
|
||||||
if (webhookName === 'setup') {
|
if (webhookName === 'setup') {
|
||||||
const webhookUrlRaw = ctx.getNodeWebhookUrl('default') as string;
|
const webhookUrlRaw = ctx.getNodeWebhookUrl('default') as string;
|
||||||
|
|
Loading…
Reference in a new issue