Comick.fun: fix chapter numbers (#10293)

This commit is contained in:
ObserverOfTime 2022-01-01 14:19:47 +02:00 committed by GitHub
parent b1d92188ab
commit 27d26f2814
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -6,7 +6,7 @@ ext {
extName = 'Comick.fun'
pkgNameSuffix = 'all.comickfun'
extClass = '.ComickFunFactory'
extVersionCode = 8
extVersionCode = 9
isNsfw = true
}

View File

@ -161,7 +161,7 @@ class SChapterDeserializer : KSerializer<SChapter> {
"vol" -> vol = decodeNullableSerializableElement(descriptor, index, serializer())
"chap" -> {
chap = decodeNullableSerializableElement(descriptor, index, serializer())
chapter_number = chap?.toFloat() ?: -1f
chapter_number = chap?.substringBefore('-')?.toFloatOrNull() ?: -1f
}
"hid" -> hid = decodeStringElement(descriptor, index)
"iso639_1" -> iso639_1 = decodeStringElement(descriptor, index)