From 3e88272277bc4c7e00599ce48c2a2f1ce117d58a Mon Sep 17 00:00:00 2001 From: Fabio Manganiello <fabio@manganiello.tech> Date: Mon, 24 Mar 2025 01:41:46 +0100 Subject: [PATCH] Always add error stack when an endpoint fails. --- src/routes/Route.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/routes/Route.ts b/src/routes/Route.ts index d109fb7..ac0e6b4 100644 --- a/src/routes/Route.ts +++ b/src/routes/Route.ts @@ -27,6 +27,7 @@ abstract class Route { protected static ServerError(req: Request, res: Response, error: Error) { console.error(`Unhandled error in ${req.method} ${req.path}: ${error}`); + console.error(error.stack); res.status(500).send('Internal Server Error'); }