Fix images not load TopTruyen (#8130)
Fix images not load and update domain TopTruyen
This commit is contained in:
parent
3fe012a4c7
commit
3bc05706e5
@ -2,8 +2,8 @@ ext {
|
|||||||
extName = 'Top Truyen'
|
extName = 'Top Truyen'
|
||||||
extClass = '.TopTruyen'
|
extClass = '.TopTruyen'
|
||||||
themePkg = 'wpcomics'
|
themePkg = 'wpcomics'
|
||||||
baseUrl = 'https://www.toptruyentv.pro'
|
baseUrl = 'https://www.toptruyentv2.pro'
|
||||||
overrideVersionCode = 9
|
overrideVersionCode = 10
|
||||||
isNsfw = true
|
isNsfw = true
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -23,7 +23,7 @@ import java.util.TimeZone
|
|||||||
class TopTruyen :
|
class TopTruyen :
|
||||||
WPComics(
|
WPComics(
|
||||||
"Top Truyen",
|
"Top Truyen",
|
||||||
"https://www.toptruyentv.pro",
|
"https://www.toptruyentv2.pro",
|
||||||
"vi",
|
"vi",
|
||||||
dateFormat = SimpleDateFormat("dd-MM-yyyy", Locale.ROOT).apply {
|
dateFormat = SimpleDateFormat("dd-MM-yyyy", Locale.ROOT).apply {
|
||||||
timeZone = TimeZone.getTimeZone("Asia/Ho_Chi_Minh")
|
timeZone = TimeZone.getTimeZone("Asia/Ho_Chi_Minh")
|
||||||
@ -37,10 +37,10 @@ class TopTruyen :
|
|||||||
.build()
|
.build()
|
||||||
|
|
||||||
override fun pageListParse(document: Document): List<Page> {
|
override fun pageListParse(document: Document): List<Page> {
|
||||||
return document.select(".page-chapter[id] img")
|
return document.select("div[id^=page_].page-chapter img").mapIndexed { index, element ->
|
||||||
.mapNotNull(::imageOrNull)
|
val img = element.attr("abs:src")
|
||||||
.distinct()
|
Page(index, imageUrl = img)
|
||||||
.mapIndexed { i, image -> Page(i, imageUrl = image) }
|
}.distinctBy { it.imageUrl }
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun popularMangaSelector() = "div.item-manga div.item"
|
override fun popularMangaSelector() = "div.item-manga div.item"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user