From 60bee14c8a059b39ab88de2ddfa7736506316b48 Mon Sep 17 00:00:00 2001 From: Ashley Date: Sun, 7 May 2023 11:28:54 +0000 Subject: [PATCH] add universe 12 :3 --- src/libpoketube/init/pages-channel-and-download.js | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/src/libpoketube/init/pages-channel-and-download.js b/src/libpoketube/init/pages-channel-and-download.js index 6be9d68b..82abd7d4 100644 --- a/src/libpoketube/init/pages-channel-and-download.js +++ b/src/libpoketube/init/pages-channel-and-download.js @@ -70,6 +70,19 @@ module.exports = function (app, config, renderTemplate) { app.get("/search", async (req, res) => { const query = req.query.query; + const poketube_universe_value = "poketube_smart_search" + + if(query.includes("youtube.com")){ + try { + var videoid = query.split("v=") + + res.redirect("/watch?v=" + videoid[1]) + } catch { + return; + } + + } + if (!query) { return res.redirect("/"); }