fix(buondua): handle single-page URL parsing case (#10714)
- Fix URL extraction when only one page exists
This commit is contained in:
parent
ff7a95faa0
commit
728dd0de50
@ -1,7 +1,7 @@
|
||||
ext {
|
||||
extName = 'Buon Dua'
|
||||
extClass = '.BuonDua'
|
||||
extVersionCode = 5
|
||||
extVersionCode = 6
|
||||
isNsfw = true
|
||||
}
|
||||
|
||||
|
@ -96,6 +96,7 @@ class BuonDua() : ParsedHttpSource() {
|
||||
// /xiuren-no-10051---10065-1127-photos-467c89d5b3e204eebe33ddbc54d905b1-47452?page=57
|
||||
val maxPage = doc.select("nav.pagination:first-of-type a.pagination-next").last()
|
||||
?.absUrl("href")
|
||||
?.takeIf { it.startsWith("http") }
|
||||
?.toHttpUrl()
|
||||
?.queryParameter("page")?.toInt() ?: 1
|
||||
val basePageUrl = response.request.url
|
||||
|
Loading…
x
Reference in New Issue
Block a user