From 864d6128a015f20d06ea26b9a8aa28d2141cfcdd Mon Sep 17 00:00:00 2001 From: Ashley Date: Wed, 20 Jul 2022 11:58:56 +0300 Subject: [PATCH] Update server.js --- server.js | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/server.js b/server.js index 7e10db1b..cdbb82fa 100644 --- a/server.js +++ b/server.js @@ -252,26 +252,17 @@ app.get("/search", async (req, res) => { q: query, }); }); - app.get("/css/:id", (req, res) => { res.sendFile(__dirname + `/css/${req.params.id}`); }); - app.get("/js/:id", (req, res) => { res.sendFile(__dirname + `/js/${req.params.id}`); }); - app.get("/video/upload", (req, res) => { res.redirect("https://youtube.com/upload?from=poketube_utc"); }); - app.get("/", async function (req, res) { - const trends = await fetch(config.tubeApi + `trending`); - const h = await trends.text(); - const k = JSON.parse(toJson(h)); - renderTemplate(res, req, "landing.ejs", { - k: k, - }); + res.redirect("/discover"); }); app.get("/api/video/download", async function (req, res) { var v = req.query.v;