From 72e747084b8df86e67f0752776b8aa23d62833a7 Mon Sep 17 00:00:00 2001 From: Guillaume Dorce Date: Thu, 10 Oct 2024 23:25:55 +0200 Subject: [PATCH] apagnan --- index.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/index.js b/index.js index 341448f..ed46b81 100644 --- a/index.js +++ b/index.js @@ -111,6 +111,10 @@ const staticDist = express.static(path.join(path.resolve(), "./public")); app.use(staticDist); -app.listen(port, () => { +const server = app.listen(port, () => { console.log(`Server listening on port ${port}`); }); + +server.on("error", (err) => { + console.error(err); +});