This commit is contained in:
ManeraKai 2022-12-10 12:06:28 +03:00
parent c19491edc0
commit 0d0ea9d2a4
No known key found for this signature in database
GPG Key ID: 5ABC31FFD562E337
2 changed files with 3 additions and 2 deletions

View File

@ -130,7 +130,8 @@ function redirect(url, type, initiator, forceRedirection) {
case "bibliogram": case "bibliogram":
const reservedPaths = ["u", "p", "privacy"] const reservedPaths = ["u", "p", "privacy"]
if (url.pathname === "/" || reservedPaths.includes(url.pathname.split("/")[1])) return `${randomInstance}${url.pathname}${url.search}` 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.replace(/\/reel|\/tv/i, "")}${url.search}` if (url.pathname.startsWith("/reel")) return `${randomInstance}${url.pathname}`
if (url.pathname.startsWith("/tv")) return `${randomInstance}/p${url.pathname.replace(/\/tv/i, "")}${url.search}`
else return `${randomInstance}/u${url.pathname}${url.search}` // Likely a user profile, redirect to '/u/...' else return `${randomInstance}/u${url.pathname}${url.search}` // Likely a user profile, redirect to '/u/...'
case "lbryDesktop": case "lbryDesktop":
return url.href.replace(/^https?:\/{2}odysee\.com\//, "lbry://").replace(/:(?=[a-zA-Z0-9])/g, "#") return url.href.replace(/^https?:\/{2}odysee\.com\//, "lbry://").replace(/:(?=[a-zA-Z0-9])/g, "#")

View File

@ -140,7 +140,7 @@
} }
}, },
"targets": [ "targets": [
"^https?:\\/{2}(www\\.)?instagram\\.com\\/?(p\\/|$)" "^https?:\\/{2}(www\\.)?instagram\\.com\\/?(p\\/|reel\\/|$)"
], ],
"name": "Instagram", "name": "Instagram",
"options": { "options": {