latisbooks: fix page loading (#11139)

my bad, I thought it worked without the extra strings, but I guess when
I tested it, the chapter cache was stale. Even with debugging tools,
Android is pain.
This commit is contained in:
Hydrox 2022-03-16 13:54:35 +00:00 committed by GitHub
parent dd2bb6cd82
commit cf07fe4326
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -5,7 +5,7 @@ ext {
extName = 'Latis Books'
pkgNameSuffix = 'en.latisbooks'
extClass = '.Latisbooks'
extVersionCode = 3
extVersionCode = 4
isNsfw = true
}

View File

@ -122,7 +122,7 @@ class Latisbooks : HttpSource() {
// Handle multiple images per page (e.g. Page 23+24)
val pages = blocks.select("img.thumb-image")
.mapIndexed { i, it -> Page(i, it.attr("abs:data-src")) }
.mapIndexed { i, it -> Page(i, "", it.attr("abs:data-src")) }
.toMutableList()
val numImages = pages.size
@ -133,7 +133,7 @@ class Latisbooks : HttpSource() {
.map { it.select("div.sqs-block-content").first() }
// Some pages have empty html blocks (e.g. Page 1), so ignore them
.filter { it.childrenSize() > 0 }
.mapIndexed { i, it -> Page(i + numImages, wordWrap(it.text()).image()) }
.mapIndexed { i, it -> Page(i + numImages, "", wordWrap(it.text()).image()) }
.toList()
)