[RU]MangaPoisk LICENSED notify deleted chapters (#18370)

* [RU]MangaPoisk LICENSED notify deleted chapters

* no supposed
This commit is contained in:
Eshlender 2023-10-04 23:48:24 +05:00 committed by GitHub
parent dfd2b6cda1
commit a1c8444d24
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 1 deletions

View File

@ -5,7 +5,7 @@ ext {
extName = 'MangaPoisk'
pkgNameSuffix = 'ru.mangapoisk'
extClass = '.MangaPoisk'
extVersionCode = 9
extVersionCode = 10
isNsfw = true
}

View File

@ -150,6 +150,10 @@ class MangaPoisk : ParsedHttpSource() {
else -> SManga.UNKNOWN
}
override fun fetchChapterList(manga: SManga): Observable<List<SChapter>> {
val document = client.newCall(GET("$baseUrl${manga.url}?tab=chapters", headers)).execute().asJsoup()
if (document.select(".text-md:contains(Главы удалены по требованию правообладателя)").isNotEmpty()) {
return Observable.error(Exception("Лицензировано - Нет глав"))
}
val pageItems = client.newCall(chapterListRequest(manga)).execute().asJsoup().select("li.page-item")
val pages = mutableListOf(1)
if (pageItems.lastIndex > 1) {