From d007f595d6831850e8c82ef33fb7e35c6296ab62 Mon Sep 17 00:00:00 2001 From: ManeraKai Date: Mon, 28 Mar 2022 21:25:08 +0300 Subject: Added support for /reel and /tv for instagram #144 --- src/assets/javascripts/helpers/instagram.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/assets/javascripts/helpers/instagram.js b/src/assets/javascripts/helpers/instagram.js index eedf1475..d151dc6b 100644 --- a/src/assets/javascripts/helpers/instagram.js +++ b/src/assets/javascripts/helpers/instagram.js @@ -97,7 +97,6 @@ function setProtocol(val) { } function redirect(url, type, initiator) { - if (disable) return; if ( initiator && @@ -116,6 +115,8 @@ function redirect(url, type, initiator) { if (url.pathname === "/" || reservedPaths.includes(url.pathname.split("/")[1])) return `${randomInstance}${url.pathname}${url.search}`; + if (url.pathname.startsWith("/reel") || url.pathname.startsWith("/tv")) + return `${randomInstance}/p${url.pathname}${url.search}`; else return `${randomInstance}/u${url.pathname}${url.search}`; // Likely a user profile, redirect to '/u/...' } -- cgit 1.4.1