From ec7583fa69250ae43b64b32b8c0c7454681ac48e Mon Sep 17 00:00:00 2001 From: "gabriel.pereira" Date: Tue, 21 Oct 2025 16:27:52 -0300 Subject: [PATCH] =?UTF-8?q?FIX:=20remover=20importa=C3=A7=C3=A3o=20duplica?= =?UTF-8?q?da=20de=20path=20e=20garantir=20que=20a=20rota=20/public=20sirv?= =?UTF-8?q?a=20arquivos=20apenas=20para=20usu=C3=A1rios=20autenticados?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app.js | 2 -- 1 file changed, 2 deletions(-) diff --git a/app.js b/app.js index 45adf6a..c70800b 100644 --- a/app.js +++ b/app.js @@ -598,8 +598,6 @@ app.get("/", (req, res) => { // servir /public APENAS quando autenticado app.use("/public", requireAuth, express.static(path.join(__dirname, "public"))); - const path = require("path"); - // rota protegida que serve o index.html app.get("/app", requireAuth, (req, res) => { res.sendFile(path.join(__dirname, "public", "index.html"));