[RU]Remanga fix detect last paid/exmanga chapter (#18006)
* [RU]Remanga fix detect last paid/exmanga chapter * autoclean * thisthat not work
This commit is contained in:
parent
a7abd1a904
commit
b9026cfdca
|
@ -6,7 +6,7 @@ ext {
|
||||||
extName = 'Remanga'
|
extName = 'Remanga'
|
||||||
pkgNameSuffix = 'ru.remanga'
|
pkgNameSuffix = 'ru.remanga'
|
||||||
extClass = '.Remanga'
|
extClass = '.Remanga'
|
||||||
extVersionCode = 78
|
extVersionCode = 79
|
||||||
}
|
}
|
||||||
|
|
||||||
dependencies {
|
dependencies {
|
||||||
|
|
|
@ -250,13 +250,7 @@ class Remanga : ConfigurableSource, HttpSource() {
|
||||||
// Do not change the title name to ensure work with a multilingual catalog!
|
// Do not change the title name to ensure work with a multilingual catalog!
|
||||||
title = if (isEng.equals("rus")) rus_name else en_name
|
title = if (isEng.equals("rus")) rus_name else en_name
|
||||||
url = "/api/titles/$dir/"
|
url = "/api/titles/$dir/"
|
||||||
thumbnail_url = if (img.high?.isNotEmpty() == true) {
|
thumbnail_url = baseUrl + img.mid
|
||||||
baseUrl + img.high
|
|
||||||
} else if (img.mid?.isNotEmpty() == true) {
|
|
||||||
baseUrl + img.mid
|
|
||||||
} else {
|
|
||||||
baseUrl + img.low
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private val simpleDateFormat by lazy { SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss", Locale.US) }
|
private val simpleDateFormat by lazy { SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss", Locale.US) }
|
||||||
|
@ -446,7 +440,7 @@ class Remanga : ConfigurableSource, HttpSource() {
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun filterPaid(tempChaptersList: MutableList<SChapter>): MutableList<SChapter> {
|
private fun filterPaid(tempChaptersList: MutableList<SChapter>): MutableList<SChapter> {
|
||||||
val lastEx = tempChaptersList.find { it.scanlator.equals("exmanga") }
|
val lastEx = tempChaptersList.find { it.scanlator.equals("exmanga") or it.url.contains("#is_bought") }
|
||||||
return if (!preferences.getBoolean(PAID_PREF, false)) {
|
return if (!preferences.getBoolean(PAID_PREF, false)) {
|
||||||
tempChaptersList.filter {
|
tempChaptersList.filter {
|
||||||
!it.name.contains("\uD83D\uDCB2") || if (lastEx != null) {
|
!it.name.contains("\uD83D\uDCB2") || if (lastEx != null) {
|
||||||
|
@ -559,9 +553,7 @@ class Remanga : ConfigurableSource, HttpSource() {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (chapter.is_paid and (chapter.is_bought == true)) {
|
if (chapter.is_paid and (chapter.is_bought == true)) {
|
||||||
if (exChID == null) {
|
url = "$url#is_bought"
|
||||||
url = "$url#is_bought"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
exChID = null
|
exChID = null
|
||||||
|
|
Loading…
Reference in New Issue