selection fixes

This commit is contained in:
Clyzer 2022-12-12 14:42:59 -03:00
parent 3ea701e94d
commit d73c9f3302

View file

@ -103,10 +103,10 @@ class MundoDonghuaProvider : MainAPI() {
"Finalizada" -> ShowStatus.Completed "Finalizada" -> ShowStatus.Completed
else -> null else -> null
} }
val specialEpisodes = doc2.selectFirst("sm-row bg-white pt-10 pr-20 pb-15 pl-20")?.selectFirst("row")?.select("item col-lg-2 col-md-2 col-xs-4")?.map { val specialEpisodes = doc2.selectFirst(".sm-row.bg-white.pt-10.pr-20.pb-15.pl-20")?.selectFirst("div.row")?.select("item col-lg-2 col-md-2 col-xs-4")?.map {
if (it.selectFirst("sf fc-dark f-bold")?.text()?.contains(title) ?: false) { if (it.selectFirst(".sf.fc-dark.f-bold")?.text()?.contains(title) ?: false) {
val name = it.selectFirst("sf fc-dark f-bold")?.text()?.replace("Episodio","-") ?: "fallo" val name = it.selectFirst("sf fc-dark f-bold")?.text()?.replace("Episodio","-") ?: "fallo"
val link = it.attr("href") val link = it.selectFirst("a")?.attr("href") ?: "fallo"
Episode(fixUrl(link), name) Episode(fixUrl(link), name)
} }
}?.filterNotNull() ?: emptyList() }?.filterNotNull() ?: emptyList()