mirror of
https://github.com/gedoor/legado.git
synced 2024-07-06 23:47:49 +08:00
优化
This commit is contained in:
parent
f81848244c
commit
cbad59f6fc
@ -273,12 +273,7 @@ open class ChangeBookSourceViewModel(application: Application) : BaseViewModel(a
|
||||
) = coroutineScope {
|
||||
val chapterIndex = if (fromReadBookActivity) {
|
||||
oldBook?.let {
|
||||
BookHelp.getDurChapter(
|
||||
it.durChapterIndex,
|
||||
it.durChapterTitle,
|
||||
chapters,
|
||||
it.totalChapterNum
|
||||
)
|
||||
BookHelp.getDurChapter(it, chapters)
|
||||
} ?: chapters.lastIndex
|
||||
} else chapters.lastIndex
|
||||
val bookChapter = chapters[chapterIndex]
|
||||
|
Loading…
Reference in New Issue
Block a user