[Ru]Remanga. Fix chapter number (#5541)

Co-authored-by: pavkazzz <me@pavkazzz.ru>
This commit is contained in:
Pavka 2021-01-25 15:28:13 +03:00 committed by GitHub
parent b24fa5b9b6
commit e1bffd90ab
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -5,7 +5,7 @@ ext {
extName = 'Remanga' extName = 'Remanga'
pkgNameSuffix = 'ru.remanga' pkgNameSuffix = 'ru.remanga'
extClass = '.Remanga' extClass = '.Remanga'
extVersionCode = 15 extVersionCode = 16
libVersion = '1.2' libVersion = '1.2'
} }

View File

@ -305,7 +305,7 @@ class Remanga : ConfigurableSource, HttpSource() {
val chapters = gson.fromJson<PageWrapperDto<BookDto>>(response.body()?.charStream()!!) val chapters = gson.fromJson<PageWrapperDto<BookDto>>(response.body()?.charStream()!!)
return chapters.content.filter { !it.is_paid or it.is_bought }.map { chapter -> return chapters.content.filter { !it.is_paid or it.is_bought }.map { chapter ->
SChapter.create().apply { SChapter.create().apply {
chapter_number = 1F chapter_number = chapter.chapter.split(".").take(2).joinToString(".").toFloat()
name = chapterName(chapter) name = chapterName(chapter)
url = "/api/titles/chapters/${chapter.id}" url = "/api/titles/chapters/${chapter.id}"
date_upload = parseDate(chapter.upload_date) date_upload = parseDate(chapter.upload_date)