fix(n8n Form Trigger Node): Fix issue preventing v1 node from working (#10364)

This commit is contained in:
Jon 2024-08-13 07:34:55 +01:00 committed by GitHub
parent 1acf674868
commit 9b647a9837
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -165,7 +165,9 @@ export async function formWebhook(
if (options.ignoreBots && isbot(req.headers['user-agent'])) {
throw new WebhookAuthorizationError(403);
}
await validateWebhookAuthentication(context, authProperty);
if (node.typeVersion > 1) {
await validateWebhookAuthentication(context, authProperty);
}
} catch (error) {
if (error instanceof WebhookAuthorizationError) {
res.writeHead(error.responseCode, { 'WWW-Authenticate': 'Basic realm="Webhook"' });