From 5a020ab2022c5ffbb731ad184de44abe42826b92 Mon Sep 17 00:00:00 2001 From: KR <79979949+justfoolingaround@users.noreply.github.com> Date: Sun, 24 Oct 2021 18:36:10 +0545 Subject: [PATCH] Fix: StreamTape extraction (#171) --- .../com/lagradost/cloudstream3/extractors/StreamTape.kt | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/app/src/main/java/com/lagradost/cloudstream3/extractors/StreamTape.kt b/app/src/main/java/com/lagradost/cloudstream3/extractors/StreamTape.kt index b5581abb..fafd9da7 100644 --- a/app/src/main/java/com/lagradost/cloudstream3/extractors/StreamTape.kt +++ b/app/src/main/java/com/lagradost/cloudstream3/extractors/StreamTape.kt @@ -11,14 +11,13 @@ class StreamTape : ExtractorApi() { override val mainUrl: String = "https://streamtape.com" override val requiresReferer = false - // Because they add concatenation to fuck up scrapers, DON'T LET LAG CODE ANYTHING private val linkRegex = - Regex("""(i(|" \+ ')d(|" \+ ')=.*?&(|" \+ ')e(|" \+ ')x(|" \+ ')p(|" \+ ')i(|" \+ ')r(|" \+ ')e(|" \+ ')s(|" \+ ')=.*?&(|" \+ ')i(|" \+ ')p(|" \+ ')=.*?&(|" \+ ')t(|" \+ ')o(|" \+ ')k(|" \+ ')e(|" \+ ')n(|" \+ ')=.*)'""") + Regex("""'robotlink'\)\.innerHTML = '(.+?)'\+ \('(.+?)'\)""") override fun getUrl(url: String, referer: String?): List? { with(get(url)) { linkRegex.find(this.text)?.let { - val extractedUrl = "https://streamtape.com/get_video?${it.groupValues[1]}".replace("""" + '""", "") + val extractedUrl = "https:${it.groups[1]!!.value + it.groups[2]!!.value.substring(3,)}" return listOf( ExtractorLink( name, @@ -32,4 +31,4 @@ class StreamTape : ExtractorApi() { } return null } -} \ No newline at end of file +}