mirror of
https://github.com/zedeus/nitter.git
synced 2024-12-12 11:06:30 +00:00
Remove Instagram -> Bibliogram replacement as it's discontinued (#772)
Close #761 Reference: https://cadence.moe/blog/2022-09-01-discontinuing-bibliogram
This commit is contained in:
parent
2751504d2f
commit
54cc790bdb
3 changed files with 0 additions and 9 deletions
|
@ -39,7 +39,6 @@ theme = "Nitter"
|
|||
replaceTwitter = "nitter.net"
|
||||
replaceYouTube = "piped.video"
|
||||
replaceReddit = "teddit.net"
|
||||
replaceInstagram = ""
|
||||
proxyVideos = true
|
||||
hlsPlayback = false
|
||||
infiniteScroll = false
|
||||
|
|
|
@ -13,7 +13,6 @@ let
|
|||
twLinkRegex = re"""<a href="https:\/\/twitter.com([^"]+)">twitter\.com(\S+)</a>"""
|
||||
|
||||
ytRegex = re(r"([A-z.]+\.)?youtu(be\.com|\.be)", {reStudy, reIgnoreCase})
|
||||
igRegex = re"(www\.)?instagram\.com"
|
||||
|
||||
rdRegex = re"(?<![.b])((www|np|new|amp|old)\.)?reddit.com"
|
||||
rdShortRegex = re"(?<![.b])redd\.it\/"
|
||||
|
@ -70,9 +69,6 @@ proc replaceUrls*(body: string; prefs: Prefs; absolute=""): string =
|
|||
if prefs.replaceReddit in result and "/gallery/" in result:
|
||||
result = result.replace("/gallery/", "/comments/")
|
||||
|
||||
if prefs.replaceInstagram.len > 0 and "instagram.com" in result:
|
||||
result = result.replace(igRegex, prefs.replaceInstagram)
|
||||
|
||||
if absolute.len > 0 and "href" in result:
|
||||
result = result.replace("href=\"/", &"href=\"{absolute}/")
|
||||
|
||||
|
|
|
@ -107,10 +107,6 @@ genPrefs:
|
|||
"Reddit -> Teddit/Libreddit"
|
||||
placeholder: "Teddit hostname"
|
||||
|
||||
replaceInstagram(input, ""):
|
||||
"Instagram -> Bibliogram"
|
||||
placeholder: "Bibliogram hostname"
|
||||
|
||||
iterator allPrefs*(): Pref =
|
||||
for k, v in prefList:
|
||||
for pref in v:
|
||||
|
|
Loading…
Reference in a new issue