Anime-Loads: fix (#1616)

This commit is contained in:
LuftVerbot 2023-05-17 19:42:13 +02:00 committed by GitHub
parent 55520120fb
commit 88e9f04011
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 309 additions and 149 deletions

View File

@ -6,7 +6,7 @@ ext {
extName = 'Anime-Loads' extName = 'Anime-Loads'
pkgNameSuffix = 'de.animeloads' pkgNameSuffix = 'de.animeloads'
extClass = '.AnimeLoads' extClass = '.AnimeLoads'
extVersionCode = 6 extVersionCode = 7
libVersion = '13' libVersion = '13'
} }

View File

@ -228,49 +228,89 @@ class AnimeLoads : ConfigurableAnimeSource, ParsedAnimeHttpSource() {
val hoster = it.substringAfter("\"hoster\":\"").substringBefore("\",\"") val hoster = it.substringAfter("\"hoster\":\"").substringBefore("\",\"")
val linkpart = it.substringAfter("\"link\":\"").substringBefore("\"}]") val linkpart = it.substringAfter("\"link\":\"").substringBefore("\"}]")
val leaveurl = client.newCall(GET("$baseUrl/leave/$linkpart")).execute().request.url.toString() val leaveurl = client.newCall(GET("$baseUrl/leave/$linkpart")).execute().request.url.toString()
val neexurl = client.newCall(GET(leaveurl)).execute().request.url.toString() if (leaveurl.contains(baseUrl)) {
val neexdoc = client.newCall(GET(leaveurl)).execute().asJsoup() val neexurl = client.newCall(GET(leaveurl)).execute().request.url.toString()
val nextlink = neexdoc.select("div#continue a").attr("href") val neexdoc = client.newCall(GET(leaveurl)).execute().asJsoup()
val anipart = nextlink.substringAfter("$baseUrl/leave/") val nextlink = neexdoc.select("div#continue a").attr("href")
Thread.sleep(10000) val anipart = nextlink.substringAfter("$baseUrl/leave/")
client.newCall(GET(nextlink, headers = Headers.headersOf("referer", neexurl))).execute().asJsoup() Thread.sleep(10000)
when { client.newCall(GET(nextlink, headers = Headers.headersOf("referer", neexurl))).execute().asJsoup()
hoster.contains("voesx") && hosterSelection?.contains("voe") == true -> { when {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString() hoster.contains("voesx") && hosterSelection?.contains("voe") == true -> {
val quality = "Voe Deutsch Sub" val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString()
val video = try { val quality = "Voe Deutsch Sub"
VoeExtractor(client).videoFromUrl(link, quality) val video = try {
} catch (e: Exception) { VoeExtractor(client).videoFromUrl(link, quality)
null } catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
} }
if (video != null) {
videoList.add(video) hoster.contains("streamtapecom") && hosterSelection?.contains("stape") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString()
val quality = "Streamtape Deutsch Sub"
val video = try {
StreamTapeExtractor(client).videoFromUrl(link, quality)
} catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
}
hoster.contains("doodstream") && hosterSelection?.contains("dood") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString()
val quality = "Doodstreams Deutsch Sub"
val video = try {
DoodExtractor(client).videoFromUrl(link, quality)
} catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
} }
} }
} else {
when {
hoster.contains("voesx") && hosterSelection?.contains("voe") == true -> {
val quality = "Voe Deutsch Sub"
val video = try {
VoeExtractor(client).videoFromUrl(leaveurl, quality)
} catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
}
hoster.contains("streamtapecom") && hosterSelection?.contains("stape") == true -> { hoster.contains("streamtapecom") && hosterSelection?.contains("stape") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString() val quality = "Streamtape Deutsch Sub"
val quality = "Streamtape Deutsch Sub" val video = try {
val video = try { StreamTapeExtractor(client).videoFromUrl(leaveurl, quality)
StreamTapeExtractor(client).videoFromUrl(link, quality) } catch (e: Exception) {
} catch (e: Exception) { null
null }
if (video != null) {
videoList.add(video)
}
} }
if (video != null) {
videoList.add(video)
}
}
hoster.contains("doodstream") && hosterSelection?.contains("dood") == true -> { hoster.contains("doodstream") && hosterSelection?.contains("dood") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString() val quality = "Doodstreams Deutsch Sub"
val quality = "Doodstreams Deutsch Sub" val video = try {
val video = try { DoodExtractor(client).videoFromUrl(leaveurl, quality)
DoodExtractor(client).videoFromUrl(link, quality) } catch (e: Exception) {
} catch (e: Exception) { null
null }
} if (video != null) {
if (video != null) { videoList.add(video)
videoList.add(video) }
} }
} }
} }
@ -324,49 +364,89 @@ class AnimeLoads : ConfigurableAnimeSource, ParsedAnimeHttpSource() {
val hoster = it.substringAfter("\"hoster\":\"").substringBefore("\",\"") val hoster = it.substringAfter("\"hoster\":\"").substringBefore("\",\"")
val linkpart = it.substringAfter("\"link\":\"").substringBefore("\"}]") val linkpart = it.substringAfter("\"link\":\"").substringBefore("\"}]")
val leaveurl = client.newCall(GET("$baseUrl/leave/$linkpart")).execute().request.url.toString() val leaveurl = client.newCall(GET("$baseUrl/leave/$linkpart")).execute().request.url.toString()
val neexurl = client.newCall(GET(leaveurl)).execute().request.url.toString() if (leaveurl.contains(baseUrl)) {
val neexdoc = client.newCall(GET(leaveurl)).execute().asJsoup() val neexurl = client.newCall(GET(leaveurl)).execute().request.url.toString()
val nextlink = neexdoc.select("div#continue a").attr("href") val neexdoc = client.newCall(GET(leaveurl)).execute().asJsoup()
val anipart = nextlink.substringAfter("$baseUrl/leave/") val nextlink = neexdoc.select("div#continue a").attr("href")
Thread.sleep(10000) val anipart = nextlink.substringAfter("$baseUrl/leave/")
client.newCall(GET(nextlink, headers = Headers.headersOf("referer", neexurl))).execute().asJsoup() Thread.sleep(10000)
when { client.newCall(GET(nextlink, headers = Headers.headersOf("referer", neexurl))).execute().asJsoup()
hoster.contains("voesx") && hosterSelection?.contains("voe") == true -> { when {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString() hoster.contains("voesx") && hosterSelection?.contains("voe") == true -> {
val quality = "Voe Deutsch Sub" val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString()
val video = try { val quality = "Voe Deutsch Sub"
VoeExtractor(client).videoFromUrl(link, quality) val video = try {
} catch (e: Exception) { VoeExtractor(client).videoFromUrl(link, quality)
null } catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
} }
if (video != null) {
videoList.add(video) hoster.contains("streamtapecom") && hosterSelection?.contains("stape") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString()
val quality = "Streamtape Deutsch Sub"
val video = try {
StreamTapeExtractor(client).videoFromUrl(link, quality)
} catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
}
hoster.contains("doodstream") && hosterSelection?.contains("dood") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString()
val quality = "Doodstreams Deutsch Sub"
val video = try {
DoodExtractor(client).videoFromUrl(link, quality)
} catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
} }
} }
} else {
when {
hoster.contains("voesx") && hosterSelection?.contains("voe") == true -> {
val quality = "Voe Deutsch Sub"
val video = try {
VoeExtractor(client).videoFromUrl(leaveurl, quality)
} catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
}
hoster.contains("streamtapecom") && hosterSelection?.contains("stape") == true -> { hoster.contains("streamtapecom") && hosterSelection?.contains("stape") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString() val quality = "Streamtape Deutsch Sub"
val quality = "Streamtape Deutsch Sub" val video = try {
val video = try { StreamTapeExtractor(client).videoFromUrl(leaveurl, quality)
StreamTapeExtractor(client).videoFromUrl(link, quality) } catch (e: Exception) {
} catch (e: Exception) { null
null }
if (video != null) {
videoList.add(video)
}
} }
if (video != null) {
videoList.add(video)
}
}
hoster.contains("doodstream") && hosterSelection?.contains("dood") == true -> { hoster.contains("doodstream") && hosterSelection?.contains("dood") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString() val quality = "Doodstreams Deutsch Sub"
val quality = "Doodstream Deutsch Sub" val video = try {
val video = try { DoodExtractor(client).videoFromUrl(leaveurl, quality)
DoodExtractor(client).videoFromUrl(link, quality) } catch (e: Exception) {
} catch (e: Exception) { null
null }
} if (video != null) {
if (video != null) { videoList.add(video)
videoList.add(video) }
} }
} }
} }
@ -482,49 +562,89 @@ class AnimeLoads : ConfigurableAnimeSource, ParsedAnimeHttpSource() {
val hoster = it.substringAfter("\"hoster\":\"").substringBefore("\",\"") val hoster = it.substringAfter("\"hoster\":\"").substringBefore("\",\"")
val linkpart = it.substringAfter("\"link\":\"").substringBefore("\"}]") val linkpart = it.substringAfter("\"link\":\"").substringBefore("\"}]")
val leaveurl = client.newCall(GET("$baseUrl/leave/$linkpart")).execute().request.url.toString() val leaveurl = client.newCall(GET("$baseUrl/leave/$linkpart")).execute().request.url.toString()
val neexurl = client.newCall(GET(leaveurl)).execute().request.url.toString() if (leaveurl.contains(baseUrl)) {
val neexdoc = client.newCall(GET(leaveurl)).execute().asJsoup() val neexurl = client.newCall(GET(leaveurl)).execute().request.url.toString()
val nextlink = neexdoc.select("div#continue a").attr("href") val neexdoc = client.newCall(GET(leaveurl)).execute().asJsoup()
val anipart = nextlink.substringAfter("$baseUrl/leave/") val nextlink = neexdoc.select("div#continue a").attr("href")
Thread.sleep(10000) val anipart = nextlink.substringAfter("$baseUrl/leave/")
client.newCall(GET(nextlink, headers = Headers.headersOf("referer", neexurl))).execute().asJsoup() Thread.sleep(10000)
when { client.newCall(GET(nextlink, headers = Headers.headersOf("referer", neexurl))).execute().asJsoup()
hoster.contains("voesx") && hosterSelection?.contains("voe") == true -> { when {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString() hoster.contains("voesx") && hosterSelection?.contains("voe") == true -> {
val quality = "Voe Deutsch Dub" val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString()
val video = try { val quality = "Voe Deutsch Dub"
VoeExtractor(client).videoFromUrl(link, quality) val video = try {
} catch (e: Exception) { VoeExtractor(client).videoFromUrl(link, quality)
null } catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
} }
if (video != null) {
videoList.add(video) hoster.contains("streamtapecom") && hosterSelection?.contains("stape") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString()
val quality = "Streamtape Deutsch Dub"
val video = try {
StreamTapeExtractor(client).videoFromUrl(link, quality)
} catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
}
hoster.contains("doodstream") && hosterSelection?.contains("dood") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString()
val quality = "Doodstream Deutsch Dub"
val video = try {
DoodExtractor(client).videoFromUrl(link, quality)
} catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
} }
} }
} else {
when {
hoster.contains("voesx") && hosterSelection?.contains("voe") == true -> {
val quality = "Voe Deutsch Dub"
val video = try {
VoeExtractor(client).videoFromUrl(leaveurl, quality)
} catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
}
hoster.contains("streamtapecom") && hosterSelection?.contains("stape") == true -> { hoster.contains("streamtapecom") && hosterSelection?.contains("stape") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString() val quality = "Streamtape Deutsch Dub"
val quality = "Streamtape Deutsch Dub" val video = try {
val video = try { StreamTapeExtractor(client).videoFromUrl(leaveurl, quality)
StreamTapeExtractor(client).videoFromUrl(link, quality) } catch (e: Exception) {
} catch (e: Exception) { null
null }
if (video != null) {
videoList.add(video)
}
} }
if (video != null) {
videoList.add(video)
}
}
hoster.contains("doodstream") && hosterSelection?.contains("dood") == true -> { hoster.contains("doodstream") && hosterSelection?.contains("dood") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString() val quality = "Doodstream Deutsch Dub"
val quality = "Doodstream Deutsch Dub" val video = try {
val video = try { DoodExtractor(client).videoFromUrl(leaveurl, quality)
DoodExtractor(client).videoFromUrl(link, quality) } catch (e: Exception) {
} catch (e: Exception) { null
null }
} if (video != null) {
if (video != null) { videoList.add(video)
videoList.add(video) }
} }
} }
} }
@ -578,49 +698,89 @@ class AnimeLoads : ConfigurableAnimeSource, ParsedAnimeHttpSource() {
val hoster = it.substringAfter("\"hoster\":\"").substringBefore("\",\"") val hoster = it.substringAfter("\"hoster\":\"").substringBefore("\",\"")
val linkpart = it.substringAfter("\"link\":\"").substringBefore("\"}]") val linkpart = it.substringAfter("\"link\":\"").substringBefore("\"}]")
val leaveurl = client.newCall(GET("$baseUrl/leave/$linkpart")).execute().request.url.toString() val leaveurl = client.newCall(GET("$baseUrl/leave/$linkpart")).execute().request.url.toString()
val neexurl = client.newCall(GET(leaveurl)).execute().request.url.toString() if (leaveurl.contains(baseUrl)) {
val neexdoc = client.newCall(GET(leaveurl)).execute().asJsoup() val neexurl = client.newCall(GET(leaveurl)).execute().request.url.toString()
val nextlink = neexdoc.select("div#continue a").attr("href") val neexdoc = client.newCall(GET(leaveurl)).execute().asJsoup()
val anipart = nextlink.substringAfter("$baseUrl/leave/") val nextlink = neexdoc.select("div#continue a").attr("href")
Thread.sleep(10000) val anipart = nextlink.substringAfter("$baseUrl/leave/")
client.newCall(GET(nextlink, headers = Headers.headersOf("referer", neexurl))).execute().asJsoup() Thread.sleep(10000)
when { client.newCall(GET(nextlink, headers = Headers.headersOf("referer", neexurl))).execute().asJsoup()
hoster.contains("voesx") && hosterSelection?.contains("voe") == true -> { when {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString() hoster.contains("voesx") && hosterSelection?.contains("voe") == true -> {
val quality = "Voe Deutsch Dub" val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString()
val video = try { val quality = "Voe Deutsch Dub"
VoeExtractor(client).videoFromUrl(link, quality) val video = try {
} catch (e: Exception) { VoeExtractor(client).videoFromUrl(link, quality)
null } catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
} }
if (video != null) {
videoList.add(video) hoster.contains("streamtapecom") && hosterSelection?.contains("stape") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString()
val quality = "Streamtape Deutsch Dub"
val video = try {
StreamTapeExtractor(client).videoFromUrl(link, quality)
} catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
}
hoster.contains("doodstream") && hosterSelection?.contains("dood") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString()
val quality = "Doodstream Deutsch Dub"
val video = try {
DoodExtractor(client).videoFromUrl(link, quality)
} catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
} }
} }
} else {
when {
hoster.contains("voesx") && hosterSelection?.contains("voe") == true -> {
val quality = "Voe Deutsch Dub"
val video = try {
VoeExtractor(client).videoFromUrl(leaveurl, quality)
} catch (e: Exception) {
null
}
if (video != null) {
videoList.add(video)
}
}
hoster.contains("streamtapecom") && hosterSelection?.contains("stape") == true -> { hoster.contains("streamtapecom") && hosterSelection?.contains("stape") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString() val quality = "Streamtape Deutsch Dub"
val quality = "Streamtape Deutsch Dub" val video = try {
val video = try { StreamTapeExtractor(client).videoFromUrl(leaveurl, quality)
StreamTapeExtractor(client).videoFromUrl(link, quality) } catch (e: Exception) {
} catch (e: Exception) { null
null }
if (video != null) {
videoList.add(video)
}
} }
if (video != null) {
videoList.add(video)
}
}
hoster.contains("doodstream") && hosterSelection?.contains("dood") == true -> { hoster.contains("doodstream") && hosterSelection?.contains("dood") == true -> {
val link = client.newCall(GET("$baseUrl/leave/$anipart")).execute().request.url.toString() val quality = "Doodstream Deutsch Dub"
val quality = "Doodstream Deutsch Dub" val video = try {
val video = try { DoodExtractor(client).videoFromUrl(leaveurl, quality)
DoodExtractor(client).videoFromUrl(link, quality) } catch (e: Exception) {
} catch (e: Exception) { null
null }
} if (video != null) {
if (video != null) { videoList.add(video)
videoList.add(video) }
} }
} }
} }