summary refs log tree commit diff
path: root/src/Server.ts
diff options
context:
space:
mode:
Diffstat (limited to 'src/Server.ts')
-rw-r--r--src/Server.ts8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/Server.ts b/src/Server.ts

index 39b1930d..52e217f8 100644 --- a/src/Server.ts +++ b/src/Server.ts
@@ -103,6 +103,14 @@ export class FosscordServer extends Server { app.use("/api/v8", prefix); app.use("/api/v9", prefix); app.use("/api", prefix); // allow unversioned requests + + prefix.get("*", (req: Request, res: Response) => { + res.status(404).json({ + message: "404: Not Found", + code: 0 + }); + }); + this.app = app; this.app.use(ErrorHandler); const indexHTML = fs.readFileSync(path.join(__dirname, "..", "client_test", "index.html"), { encoding: "utf8" });