diff options
author | 2023-11-30 10:03:51 -0500 | |
---|---|---|
committer | 2023-11-30 10:03:51 -0500 | |
commit | fbf145af8a792ee7334be577fbdf0bba9782b4e7 (patch) | |
tree | a5212b8b8f12d734579db8a2bb90dd4c772cba44 /packages/integrations/node/src/nodeMiddleware.ts | |
parent | ff8eadb95d34833baaf3ec7575bf4f293eae97da (diff) | |
parent | 05628aaa3c9a3702b59cbf3d0e99abf66df651df (diff) | |
download | astro-fbf145af8a792ee7334be577fbdf0bba9782b4e7.tar.gz astro-fbf145af8a792ee7334be577fbdf0bba9782b4e7.tar.zst astro-fbf145af8a792ee7334be577fbdf0bba9782b4e7.zip |
Merge pull request #9247 from withastro/next
Merge the `next` branch into `main` for the 4.0 release
Diffstat (limited to 'packages/integrations/node/src/nodeMiddleware.ts')
-rw-r--r-- | packages/integrations/node/src/nodeMiddleware.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/packages/integrations/node/src/nodeMiddleware.ts b/packages/integrations/node/src/nodeMiddleware.ts index 4fd0a4bc2..0b9381f1d 100644 --- a/packages/integrations/node/src/nodeMiddleware.ts +++ b/packages/integrations/node/src/nodeMiddleware.ts @@ -30,10 +30,10 @@ export default function (app: NodeApp, mode: Options['mode']) { } try { - const route = app.match(req); - if (route) { + const routeData = app.match(req); + if (routeData) { try { - const response = await app.render(req, route, locals); + const response = await app.render(req, { routeData, locals }); await writeWebResponse(app, res, response); } catch (err: unknown) { if (next) { |