From a0b0f1c33c8e9db0084ee503c685a99474b21af7 Mon Sep 17 00:00:00 2001 From: Ashley Date: Sun, 7 Aug 2022 16:16:59 +0300 Subject: [PATCH] download owo --- server.js | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/server.js b/server.js index 7eae428..76ca59a 100644 --- a/server.js +++ b/server.js @@ -330,8 +330,12 @@ app.get("/", async function (req, res) { app.get("/api/video/download", async function (req, res) { var v = req.query.v; var fetching = await fetcher(v); - const url = fetching.video.Player.Formats.Format[1].URL; - res.redirect(url); + + const json = fetching.video.Player; + + const url = `https://tube.kuylar.dev/proxy/download/${v}/22/${json.title}.mp4` + + res.redirect(url) }); app.get("/api/video/downloadjson", async function (req, res) {