From 2e504281d952f3c7ce7d1d241f2c717046f37562 Mon Sep 17 00:00:00 2001 From: Neville Mehta Date: Thu, 18 Jul 2024 20:22:07 -0700 Subject: [PATCH] Revert "handle errors on dyamic import of middleware" This reverts commit bc26e5b5e53976b3f62c4bea1a03410ea3679718. --- packages/integrations/node/src/standalone.ts | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/packages/integrations/node/src/standalone.ts b/packages/integrations/node/src/standalone.ts index 9964b187e39a..ede5086f2ea2 100644 --- a/packages/integrations/node/src/standalone.ts +++ b/packages/integrations/node/src/standalone.ts @@ -34,10 +34,7 @@ export default async function standalone(app: NodeApp, options: Options) { // also used by server entrypoint export async function createStandaloneHandler(app: NodeApp, options: Options) { - let importMiddleware = null; - try { - importMiddleware = options.middleware ? await import(options.middleware) : null; - } catch (err) {} + const importMiddleware = options.middleware ? await import(options.middleware) : null; const appHandler = createAppHandler(app); const staticHandler = createStaticHandler(app, options); return (req: http.IncomingMessage, res: http.ServerResponse) => {