diff --git a/src/app.js b/src/app.js index 5198a0a..de9f10b 100644 --- a/src/app.js +++ b/src/app.js @@ -32,9 +32,12 @@ setupMiddleware(app); -app.listen(3400, () => { +port = process.env.PORT || 3400 + +app.listen(port, () => { console.log("Server listening on http://localhost:3400"); }); + // Global error handlers for uncaught exceptions and rejections process.on("uncaughtException", (err) => { console.error("Uncaught Exception:", err);