diff --git a/back-end/src/routes/index.ts b/back-end/src/routes/index.ts index 6b1eda7..ec1dd3b 100644 --- a/back-end/src/routes/index.ts +++ b/back-end/src/routes/index.ts @@ -26,4 +26,9 @@ routes.use("/marques", getUsername, verifyAuthentication, marquesRoute); routes.use("/membres", memberRouter); routes.use("/models", modelRouter); +// 404 fallback +routes.get("*", (_req, res) => { + res.render('notfound.ejs'); +}); + export default routes; diff --git a/back-end/src/templates/notfound.ejs b/back-end/src/templates/notfound.ejs index e69de29..d0314d5 100644 --- a/back-end/src/templates/notfound.ejs +++ b/back-end/src/templates/notfound.ejs @@ -0,0 +1,19 @@ + + + + + + + 404 -- Not Found + + + <%- include('partials/links.ejs') %> + + + <%- include('partials/header.ejs') %> + +

+ ¯\_(ツ)_/¯ +

+ +