mirror of
https://github.com/Suwayomi/TachideskJUI.git
synced 2025-12-10 06:42:05 +01:00
Fix reader mode not updating after changing the value
This commit is contained in:
@@ -9,6 +9,7 @@ package ca.gosyer.jui.domain.manga.interactor
|
||||
import ca.gosyer.jui.domain.ServerListeners
|
||||
import ca.gosyer.jui.domain.manga.model.Manga
|
||||
import ca.gosyer.jui.domain.manga.service.MangaRepository
|
||||
import io.ktor.http.encodeURLQueryComponent
|
||||
import kotlinx.coroutines.flow.catch
|
||||
import kotlinx.coroutines.flow.collect
|
||||
import kotlinx.coroutines.flow.flow
|
||||
@@ -35,7 +36,7 @@ class UpdateMangaMeta @Inject constructor(
|
||||
manga: Manga,
|
||||
readerMode: String = manga.meta.juiReaderMode
|
||||
) = flow {
|
||||
if (readerMode != manga.meta.juiReaderMode) {
|
||||
if (readerMode.encodeURLQueryComponent() != manga.meta.juiReaderMode.encodeURLQueryComponent()) {
|
||||
mangaRepository.updateMangaMeta(
|
||||
manga.id,
|
||||
"juiReaderMode",
|
||||
|
||||
Reference in New Issue
Block a user