From f7cc36f2f00ff8bcc690a0e5e94b1464f014e3b6 Mon Sep 17 00:00:00 2001 From: arkon Date: Sat, 17 Apr 2021 11:38:08 -0400 Subject: [PATCH] Follow chapter sort setting for start/resume FAB (closes #1716) --- .../main/java/eu/kanade/tachiyomi/ui/manga/MangaPresenter.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaPresenter.kt b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaPresenter.kt index 11672cd3dc..109732e573 100644 --- a/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaPresenter.kt +++ b/app/src/main/java/eu/kanade/tachiyomi/ui/manga/MangaPresenter.kt @@ -474,7 +474,7 @@ class MangaPresenter( * Returns the next unread chapter or null if everything is read. */ fun getNextUnreadChapter(): ChapterItem? { - return chapters.sortedByDescending { it.source_order }.find { !it.read } + return chapters.sortedWith(getChapterSort()).findLast { !it.read } } /**