From 1887dab86be83da3fc947a22dde0f5a02cad9d49 Mon Sep 17 00:00:00 2001 From: Razvan Stoenescu Date: Tue, 29 Mar 2022 13:12:16 +0300 Subject: [PATCH] fix(app-vite): "request" instead of "req" for SSR devserver #12972 --- app-vite/lib/modes/ssr/ssr-devserver.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app-vite/lib/modes/ssr/ssr-devserver.js b/app-vite/lib/modes/ssr/ssr-devserver.js index e29767fad18..50209eaf111 100644 --- a/app-vite/lib/modes/ssr/ssr-devserver.js +++ b/app-vite/lib/modes/ssr/ssr-devserver.js @@ -307,7 +307,7 @@ class SsrDevServer extends AppDevserver { const { publicPath } = this.#appOptions publicPath !== '/' && app.use((req, res, next) => { - const pathname = new URL(req.url, `http://${request.headers.host}`).pathname || '/' + const pathname = new URL(req.url, `http://${req.headers.host}`).pathname || '/' if (pathname.startsWith(publicPath) === true) { next()