fix early manga chapter list (#5901)

This commit is contained in:
Riztard Lanthorn 2021-02-18 08:26:07 +07:00 committed by GitHub
parent 64336e1567
commit 09c569db4d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 4 deletions

View File

@ -5,7 +5,7 @@ ext {
extName = 'EarlyManga'
pkgNameSuffix = 'en.earlymanga'
extClass = '.EarlyManga'
extVersionCode = 9
extVersionCode = 10
libVersion = '1.2'
}

View File

@ -126,8 +126,8 @@ class EarlyManga : ParsedHttpSource() {
override fun chapterListSelector() = ".chapter-container > .row:not(:first-child)"
override fun chapterFromElement(element: Element) = SChapter.create().apply {
setUrlWithoutDomain(element.select(".col>.row>.col-lg-5:not([style*=display:]) a[href*=chapter]:not([style*=display:])").attr("href"))
name = element.select(".col>.row>.col-lg-5:not([style*=display:]) a[href*=chapter]:not([style*=display:])").attr("href").substringAfter("chapter")
setUrlWithoutDomain(element.select(".col>.row>.col-lg-5:not([style*=display:]):not(.d-none) a[href*=chapter]:not([style*=display:])").attr("href"))
name = element.select(".col>.row>.col-lg-5:not([style*=display:]):not(.d-none) a[href*=chapter]:not([style*=display:])").attr("href").substringAfter("chapter")
name = "Chapter" + name
date_upload = parseChapterDate(element.select(".ml-1").attr("title"))
}
@ -138,7 +138,8 @@ class EarlyManga : ParsedHttpSource() {
// pages
override fun pageListParse(document: Document): List<Page> {
return document.select("img[src*=manga],img[src*=chapter],div>div>img[src]"
return document.select(
"img[src*=manga],img[src*=chapter],div>div>img[src]"
).mapIndexed { i, element ->
Page(i, "", element.attr("abs:src"))
}