From cbe00e9a9ea2f890126a7f13c8c27507cf592098 Mon Sep 17 00:00:00 2001 From: "Glitch (hello-express)" Date: Thu, 19 Dec 2019 12:49:01 +0000 Subject: [PATCH] =?UTF-8?q?=F0=9F=92=92=F0=9F=8C=A5=20Checkpoint=20./serve?= =?UTF-8?q?r.js:933874/59?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- server.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server.js b/server.js index 009c2d4..9a040dc 100644 --- a/server.js +++ b/server.js @@ -35,7 +35,7 @@ const redirectToHTTPS = (req, res, next) => { app.use("/api", redirectToHTTPS); app.use("/img", redirectToHTTPS); -app.get("/", redirectToHTTPS); +app.all("/", redirectToHTTPS); // no app.use here because it would match every path app.get("/", (req, res) => { res.sendFile(__dirname + "/views/index.html"); });