chore: Sync with latest commits
This commit is contained in:
parent
9b96273df0
commit
56c945d716
115 changed files with 2230 additions and 445 deletions
|
@ -1,7 +1,7 @@
|
|||
ext {
|
||||
extName = 'Anime-Sama'
|
||||
extClass = '.AnimeSama'
|
||||
extVersionCode = 9
|
||||
extVersionCode = 10
|
||||
}
|
||||
|
||||
apply from: "$rootDir/common.gradle"
|
||||
|
|
|
@ -19,6 +19,7 @@ import eu.kanade.tachiyomi.util.asJsoup
|
|||
import eu.kanade.tachiyomi.util.parallelCatchingFlatMap
|
||||
import kotlinx.serialization.encodeToString
|
||||
import kotlinx.serialization.json.Json
|
||||
import okhttp3.HttpUrl.Companion.toHttpUrl
|
||||
import okhttp3.Request
|
||||
import okhttp3.Response
|
||||
import uy.kohesive.injekt.Injekt
|
||||
|
@ -64,9 +65,13 @@ class AnimeSama : ConfigurableAnimeSource, AnimeHttpSource() {
|
|||
// =============================== Latest ===============================
|
||||
override fun latestUpdatesParse(response: Response): AnimesPage {
|
||||
val animes = response.asJsoup()
|
||||
val seasons = animes.select("h2:contains(derniers ajouts) + .scrollBarStyled > div").flatMap {
|
||||
val animeUrl = it.getElementsByTag("a").attr("href")
|
||||
fetchAnimeSeasons(animeUrl)
|
||||
val seasons = animes.select("#containerAjoutsAnimes > div").flatMap {
|
||||
val animeUrl = it.getElementsByTag("a").attr("href").toHttpUrl()
|
||||
val url = animeUrl.newBuilder()
|
||||
.removePathSegment(animeUrl.pathSize - 2)
|
||||
.removePathSegment(animeUrl.pathSize - 3)
|
||||
.build()
|
||||
fetchAnimeSeasons(url.toString())
|
||||
}
|
||||
return AnimesPage(seasons, false)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue