mirror of
https://github.com/hexated/cloudstream-extensions-hexated.git
synced 2024-08-15 00:03:22 +00:00
fixed Animixplay main server
This commit is contained in:
parent
cb45b2c159
commit
4f4755bf56
3 changed files with 20 additions and 8 deletions
|
@ -1,5 +1,5 @@
|
||||||
// use an integer for version numbers
|
// use an integer for version numbers
|
||||||
version = 3
|
version = 4
|
||||||
|
|
||||||
|
|
||||||
cloudstream {
|
cloudstream {
|
||||||
|
|
|
@ -188,7 +188,7 @@ class Animixplay : MainAPI() {
|
||||||
).parsedSafe<DataAni>()?.data?.media?.id
|
).parsedSafe<DataAni>()?.data?.media?.id
|
||||||
|
|
||||||
val res = app.get("$mainUrl/assets/mal/$malId.json").parsedSafe<AnimeDetail>()
|
val res = app.get("$mainUrl/assets/mal/$malId.json").parsedSafe<AnimeDetail>()
|
||||||
?: throw ErrorLoadingException("Invalid json responses")
|
?: throw ErrorLoadingException("No data found")
|
||||||
|
|
||||||
val subEpisodes = mutableListOf<Episode>()
|
val subEpisodes = mutableListOf<Episode>()
|
||||||
val dubEpisodes = mutableListOf<Episode>()
|
val dubEpisodes = mutableListOf<Episode>()
|
||||||
|
|
|
@ -140,12 +140,24 @@ class GogoanimeProvider : MainAPI() {
|
||||||
source: GogoSource,
|
source: GogoSource,
|
||||||
sourceCallback: (ExtractorLink) -> Unit
|
sourceCallback: (ExtractorLink) -> Unit
|
||||||
) {
|
) {
|
||||||
M3u8Helper.generateM3u8(
|
if (source.file.contains(".m3u8")) {
|
||||||
mainApiName,
|
M3u8Helper.generateM3u8(
|
||||||
source.file,
|
mainApiName,
|
||||||
mainUrl,
|
source.file,
|
||||||
headers = mapOf("Origin" to "https://plyr.link")
|
mainUrl,
|
||||||
).forEach(sourceCallback)
|
headers = mapOf("Origin" to "https://plyr.link")
|
||||||
|
).forEach(sourceCallback)
|
||||||
|
} else {
|
||||||
|
sourceCallback.invoke(
|
||||||
|
ExtractorLink(
|
||||||
|
mainApiName,
|
||||||
|
mainApiName,
|
||||||
|
source.file,
|
||||||
|
mainUrl,
|
||||||
|
getQualityFromName(source.label),
|
||||||
|
)
|
||||||
|
)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sources.source?.forEach {
|
sources.source?.forEach {
|
||||||
|
|
Loading…
Reference in a new issue