diff --git a/MundoDonghuaProvider/src/main/kotlin/com/lagradost/MundoDonghuaProvider.kt b/MundoDonghuaProvider/src/main/kotlin/com/lagradost/MundoDonghuaProvider.kt index 796ea0e..01ffd28 100644 --- a/MundoDonghuaProvider/src/main/kotlin/com/lagradost/MundoDonghuaProvider.kt +++ b/MundoDonghuaProvider/src/main/kotlin/com/lagradost/MundoDonghuaProvider.kt @@ -23,15 +23,6 @@ class MundoDonghuaProvider : MainAPI() { TvType.Anime, ) val docSpecial = app.get(mainUrl, timeout = 120).document - val specialEpisodes = docSpecial.select("div.sm-row.bg-white.pt-10.pr-20.pb-15.pl-20 div.item.col-lg-2.col-md-2.col-xs-4").mapNotNull { - val name = it.selectFirst("h5")?.text()?.replace("Episodio","-") ?: "" - val link = it.selectFirst("a")?.attr("href") ?: "" - if (name.contains(title, true)) { - Episode(fixUrl(link), name) - } else { - null - } - }.reversed() override suspend fun getMainPage(page: Int, request : MainPageRequest): HomePageResponse { val urls = listOf( @@ -102,7 +93,6 @@ class MundoDonghuaProvider : MainAPI() { override suspend fun load(url: String): LoadResponse { val doc = app.get(url, timeout = 120).document - val docSpecial = app.get(mainUrl, timeout = 120).document val poster = doc.selectFirst("head meta[property=og:image]")?.attr("content") ?: "" val title = doc.selectFirst(".ls-title-serie")?.text() ?: "" val description = doc.selectFirst("p.text-justify.fc-dark")?.text() ?: "" @@ -112,6 +102,15 @@ class MundoDonghuaProvider : MainAPI() { "Finalizada" -> ShowStatus.Completed else -> null } + val specialEpisodes = docSpecial.select("div.sm-row.bg-white.pt-10.pr-20.pb-15.pl-20 div.item.col-lg-2.col-md-2.col-xs-4").mapNotNull { + val name = it.selectFirst("h5")?.text()?.replace("Episodio","-") ?: "" + val link = it.selectFirst("a")?.attr("href") ?: "" + if (name.contains(title, true)) { + Episode(fixUrl(link), name) + } else { + null + } + }.reversed() val episodes = doc.select("ul.donghua-list a").map { val name = it.selectFirst(".fs-16")?.text() val link = it.attr("href")