mirror of
https://github.com/n8n-io/n8n.git
synced 2025-01-24 11:02:12 -08:00
fix(core): Guard against node not found on cancelling test webhook (#7750)
https://n8nio.sentry.io/issues/4623682198
This commit is contained in:
parent
82f3202a2d
commit
6be453b716
|
@ -1048,7 +1048,10 @@ export class Workflow {
|
||||||
activation: WorkflowActivateMode,
|
activation: WorkflowActivateMode,
|
||||||
isTest?: boolean,
|
isTest?: boolean,
|
||||||
): Promise<boolean | undefined> {
|
): Promise<boolean | undefined> {
|
||||||
const node = this.getNode(webhookData.node) as INode;
|
const node = this.getNode(webhookData.node);
|
||||||
|
|
||||||
|
if (!node) return;
|
||||||
|
|
||||||
const nodeType = this.nodeTypes.getByNameAndVersion(node.type, node.typeVersion);
|
const nodeType = this.nodeTypes.getByNameAndVersion(node.type, node.typeVersion);
|
||||||
|
|
||||||
const webhookFn = nodeType.webhookMethods?.[webhookData.webhookDescription.name]?.[method];
|
const webhookFn = nodeType.webhookMethods?.[webhookData.webhookDescription.name]?.[method];
|
||||||
|
|
Loading…
Reference in a new issue