Fix proxy method not working on Cubari. (#7431)
This commit is contained in:
parent
6d144464c7
commit
5295e43d68
|
@ -6,7 +6,7 @@ ext {
|
||||||
extName = 'Cubari'
|
extName = 'Cubari'
|
||||||
pkgNameSuffix = "all.cubari"
|
pkgNameSuffix = "all.cubari"
|
||||||
extClass = '.CubariFactory'
|
extClass = '.CubariFactory'
|
||||||
extVersionCode = 6
|
extVersionCode = 7
|
||||||
libVersion = '1.2'
|
libVersion = '1.2'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -268,6 +268,7 @@ open class Cubari(override val lang: String) : HttpSource() {
|
||||||
val chapterNum = chapterEntry.key
|
val chapterNum = chapterEntry.key
|
||||||
val chapterObj = chapterEntry.value.jsonObject
|
val chapterObj = chapterEntry.value.jsonObject
|
||||||
val chapterGroups = chapterObj["groups"]!!.jsonObject
|
val chapterGroups = chapterObj["groups"]!!.jsonObject
|
||||||
|
val volume = chapterObj["volume"]!!.jsonPrimitive.content
|
||||||
|
|
||||||
chapterGroups.entries.map { groupEntry ->
|
chapterGroups.entries.map { groupEntry ->
|
||||||
val groupNum = groupEntry.key
|
val groupNum = groupEntry.key
|
||||||
|
@ -288,7 +289,7 @@ open class Cubari(override val lang: String) : HttpSource() {
|
||||||
seriesPrefs.getLong(chapterNum, currentTimeMillis)
|
seriesPrefs.getLong(chapterNum, currentTimeMillis)
|
||||||
}
|
}
|
||||||
|
|
||||||
name = if (chapterObj["volume"]!!.jsonPrimitive.content != "Uncategorized") {
|
name = if (volume.isNotEmpty() && volume != "Uncategorized") {
|
||||||
// Output "Vol. 1 Ch. 1 - Chapter Name"
|
// Output "Vol. 1 Ch. 1 - Chapter Name"
|
||||||
"Vol. " + chapterObj["volume"]!!.jsonPrimitive.content + " Ch. " +
|
"Vol. " + chapterObj["volume"]!!.jsonPrimitive.content + " Ch. " +
|
||||||
chapterNum + " - " + chapterObj["title"]!!.jsonPrimitive.content
|
chapterNum + " - " + chapterObj["title"]!!.jsonPrimitive.content
|
||||||
|
@ -297,7 +298,7 @@ open class Cubari(override val lang: String) : HttpSource() {
|
||||||
"Ch. " + chapterNum + " - " + chapterObj["title"]!!.jsonPrimitive.content
|
"Ch. " + chapterNum + " - " + chapterObj["title"]!!.jsonPrimitive.content
|
||||||
}
|
}
|
||||||
|
|
||||||
url = if (chapterGroups[groupNum] != null) {
|
url = if (chapterGroups[groupNum] is JsonArray) {
|
||||||
"${manga.url}/$chapterNum/$groupNum"
|
"${manga.url}/$chapterNum/$groupNum"
|
||||||
} else {
|
} else {
|
||||||
chapterGroups[groupNum]!!.jsonPrimitive.content
|
chapterGroups[groupNum]!!.jsonPrimitive.content
|
||||||
|
|
Loading…
Reference in New Issue