From 50c76a45f596afa6575eb5577ab06bb99cdadbce Mon Sep 17 00:00:00 2001 From: metamuffin Date: Tue, 14 Sep 2021 21:07:24 +0200 Subject: it probably doesnt make sense to comment commits at this point --- source/index.ts | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'source/index.ts') diff --git a/source/index.ts b/source/index.ts index 816b513..e22478e 100644 --- a/source/index.ts +++ b/source/index.ts @@ -15,17 +15,16 @@ const render_env = { app.set("view engine", "pug") app.set("views", join(__dirname, "../views")) -app.get("/", (req, res) => { -}) -app.get("/licence", async (req, res) => { - const content = (await readFile(join(__dirname, "../LICENCE"))).toString() - res.type("text/plain").send(content) -}) +app.get("/", (req, res) => res.redirect("/about")) app.get("/about", (req, res) => res.render("about", render_env)) app.get("/projects", (req, res) => res.render("projects", render_env)) app.get("/contact", (req, res) => res.render("contact", render_env)) +app.get("/licence", async (req, res) => { + const content = (await readFile(join(__dirname, "../LICENCE"))).toString() + res.type("text/plain").send(content) +}) const PORT = parseInt(process.env.PORT ?? "8080") const HOST = process.env.HOST || "127.0.0.1" -- cgit v1.2.3-70-g09d2