mirror of
https://github.com/makeplane/plane.git
synced 2025-12-16 11:57:56 +01:00
[WIKI-565] chore: handle 404 messages in live server (#7472)
* chore: handle 404 messages in live server * chore: removed error stack from response
This commit is contained in:
committed by
GitHub
parent
2746bad86b
commit
849b7b7bf3
@@ -1,3 +1,4 @@
|
||||
PORT=3100
|
||||
API_BASE_URL="http://localhost:8000"
|
||||
|
||||
WEB_BASE_URL="http://localhost:3000"
|
||||
|
||||
@@ -82,14 +82,16 @@ export class Server {
|
||||
});
|
||||
} catch (error) {
|
||||
manualLogger.error("Error in /convert-document endpoint:", error);
|
||||
res.status(500).send({
|
||||
message: `Internal server error. ${error}`,
|
||||
res.status(500).json({
|
||||
message: `Internal server error.`,
|
||||
});
|
||||
}
|
||||
});
|
||||
|
||||
this.app.use((_req: Request, res: Response) => {
|
||||
res.status(404).send("Not Found");
|
||||
res.status(404).json({
|
||||
message: "Not Found",
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user