Albirew/tachiyomi
Archivé
1
0
Bifurcation 0

Handle chapter read status in correct order

Fixes #9687
Cette révision appartient à :
arkon 2023-07-09 09:54:05 -04:00
Parent 7c62453280
révision 1e3d9a00f2

Voir le fichier

@ -510,6 +510,12 @@ class ReaderViewModel(
readerChapter.requestedPage = pageIndex readerChapter.requestedPage = pageIndex
readerChapter.chapter.last_page_read = pageIndex readerChapter.chapter.last_page_read = pageIndex
if (readerChapter.pages?.lastIndex == pageIndex) {
readerChapter.chapter.read = true
updateTrackChapterRead(readerChapter)
deleteChapterIfNeeded(readerChapter)
}
updateChapter.await( updateChapter.await(
ChapterUpdate( ChapterUpdate(
id = readerChapter.chapter.id!!, id = readerChapter.chapter.id!!,
@ -518,12 +524,6 @@ class ReaderViewModel(
lastPageRead = readerChapter.chapter.last_page_read.toLong(), lastPageRead = readerChapter.chapter.last_page_read.toLong(),
), ),
) )
if (readerChapter.pages?.lastIndex == pageIndex) {
readerChapter.chapter.read = true
updateTrackChapterRead(readerChapter)
deleteChapterIfNeeded(readerChapter)
}
} }
} }