diff --git a/src/lib/functions/form-submissions-handler.mjs b/src/lib/functions/form-submissions-handler.mjs index c3735dc6dfe..b31605e476c 100644 --- a/src/lib/functions/form-submissions-handler.mjs +++ b/src/lib/functions/form-submissions-handler.mjs @@ -29,7 +29,12 @@ const getFormHandler = function ({ functionsRegistry }) { export const createFormSubmissionHandler = function ({ functionsRegistry, siteUrl }) { return async function formSubmissionHandler(req, res, next) { - if (req.url.startsWith('/.netlify/') ||req.method !== 'POST' || (await functionsRegistry.getFunctionForURLPath(req.url, req.method))) return next() + if ( + req.url.startsWith('/.netlify/') || + req.method !== 'POST' || + (await functionsRegistry.getFunctionForURLPath(req.url, req.method)) + ) + return next() const fakeRequest = new Readable({ read() {