Reimplement chapter download indicator longpress (#7412)

This commit is contained in:
AntsyLich
2022-07-02 22:43:18 +06:00
committed by GitHub
parent f3c50ee9a3
commit deaded5af2
8 changed files with 169 additions and 4 deletions

View File

@@ -92,6 +92,10 @@ class ChapterRepositoryImpl(
return handler.awaitList { chaptersQueries.getChaptersByMangaId(mangaId, chapterMapper) }
}
override suspend fun getChapterById(id: Long): Chapter? {
return handler.awaitOneOrNull { chaptersQueries.getChapterById(id, chapterMapper) }
}
override suspend fun getChapterByMangaIdAsFlow(mangaId: Long): Flow<List<Chapter>> {
return handler.subscribeToList { chaptersQueries.getChaptersByMangaId(mangaId, chapterMapper) }
}