MangaPark - fix thumbnails (#2537)
This commit is contained in:
parent
e3b870a1db
commit
7f7fe11e4e
@ -5,7 +5,7 @@ ext {
|
|||||||
appName = 'Tachiyomi: MangaPark'
|
appName = 'Tachiyomi: MangaPark'
|
||||||
pkgNameSuffix = 'en.mangapark'
|
pkgNameSuffix = 'en.mangapark'
|
||||||
extClass = '.MangaPark'
|
extClass = '.MangaPark'
|
||||||
extVersionCode = 10
|
extVersionCode = 11
|
||||||
libVersion = '1.2'
|
libVersion = '1.2'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -43,11 +43,6 @@ class MangaPark : ConfigurableSource, ParsedHttpSource() {
|
|||||||
private val dateFormat = SimpleDateFormat("MMM d, yyyy, HH:mm a", Locale.ENGLISH)
|
private val dateFormat = SimpleDateFormat("MMM d, yyyy, HH:mm a", Locale.ENGLISH)
|
||||||
private val dateFormatTimeOnly = SimpleDateFormat("HH:mm a", Locale.ENGLISH)
|
private val dateFormatTimeOnly = SimpleDateFormat("HH:mm a", Locale.ENGLISH)
|
||||||
|
|
||||||
private fun cleanUrl(url: String) = if (url.startsWith("//"))
|
|
||||||
"https:$url"
|
|
||||||
else url
|
|
||||||
|
|
||||||
|
|
||||||
override fun popularMangaRequest(page: Int) = GET("$baseUrl$directoryUrl/$page?views_a")
|
override fun popularMangaRequest(page: Int) = GET("$baseUrl$directoryUrl/$page?views_a")
|
||||||
|
|
||||||
override fun popularMangaSelector() = directorySelector
|
override fun popularMangaSelector() = directorySelector
|
||||||
@ -92,11 +87,10 @@ class MangaPark : ConfigurableSource, ParsedHttpSource() {
|
|||||||
|
|
||||||
@SuppressLint("DefaultLocale")
|
@SuppressLint("DefaultLocale")
|
||||||
override fun mangaDetailsParse(document: Document) = SManga.create().apply {
|
override fun mangaDetailsParse(document: Document) = SManga.create().apply {
|
||||||
val coverElement = document.select(".cover > img").first()
|
document.select(".cover > img").first().let { coverElement ->
|
||||||
|
title = coverElement.attr("title")
|
||||||
title = coverElement.attr("title")
|
thumbnail_url = coverElement.attr("abs:src")
|
||||||
|
}
|
||||||
thumbnail_url = cleanUrl(coverElement.attr("src"))
|
|
||||||
|
|
||||||
document.select(".attr > tbody > tr").forEach {
|
document.select(".attr > tbody > tr").forEach {
|
||||||
when (it.getElementsByTag("th").first().text().trim().toLowerCase()) {
|
when (it.getElementsByTag("th").first().text().trim().toLowerCase()) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user