diff --git a/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/backup/interactor/ValidateBackupFile.kt b/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/backup/interactor/ValidateBackupFile.kt index c3f85ec7..6cf3b13d 100644 --- a/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/backup/interactor/ValidateBackupFile.kt +++ b/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/backup/interactor/ValidateBackupFile.kt @@ -7,10 +7,8 @@ package ca.gosyer.jui.domain.backup.interactor import ca.gosyer.jui.domain.backup.service.BackupRepository -import ca.gosyer.jui.domain.category.service.CategoryRepository import io.ktor.client.request.HttpRequestBuilder import kotlinx.coroutines.flow.catch -import kotlinx.coroutines.flow.collect import kotlinx.coroutines.flow.singleOrNull import me.tatarka.inject.annotations.Inject import okio.Path diff --git a/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/chapter/interactor/GetChapters.kt b/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/chapter/interactor/GetChapters.kt index 89b85d4b..e26369c6 100644 --- a/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/chapter/interactor/GetChapters.kt +++ b/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/chapter/interactor/GetChapters.kt @@ -8,7 +8,6 @@ package ca.gosyer.jui.domain.chapter.interactor import ca.gosyer.jui.domain.chapter.service.ChapterRepository import ca.gosyer.jui.domain.manga.model.Manga -import ca.gosyer.jui.domain.manga.service.MangaRepository import kotlinx.coroutines.flow.catch import kotlinx.coroutines.flow.singleOrNull import me.tatarka.inject.annotations.Inject diff --git a/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/chapter/interactor/StopChapterDownload.kt b/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/chapter/interactor/StopChapterDownload.kt index 346d5772..7f05778b 100644 --- a/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/chapter/interactor/StopChapterDownload.kt +++ b/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/chapter/interactor/StopChapterDownload.kt @@ -11,7 +11,6 @@ import ca.gosyer.jui.domain.chapter.service.ChapterRepository import ca.gosyer.jui.domain.manga.model.Manga import kotlinx.coroutines.flow.catch import kotlinx.coroutines.flow.collect -import kotlinx.coroutines.flow.singleOrNull import me.tatarka.inject.annotations.Inject import org.lighthousegames.logging.logging diff --git a/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/download/interactor/StartDownloading.kt b/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/download/interactor/StartDownloading.kt index 6c0276e2..4ee6f62a 100644 --- a/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/download/interactor/StartDownloading.kt +++ b/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/download/interactor/StartDownloading.kt @@ -7,7 +7,6 @@ package ca.gosyer.jui.domain.download.interactor import ca.gosyer.jui.domain.download.service.DownloadRepository -import ca.gosyer.jui.domain.updates.service.UpdatesRepository import kotlinx.coroutines.flow.catch import kotlinx.coroutines.flow.collect import me.tatarka.inject.annotations.Inject diff --git a/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/extension/interactor/InstallExtension.kt b/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/extension/interactor/InstallExtension.kt index 9c2abad0..93288ae3 100644 --- a/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/extension/interactor/InstallExtension.kt +++ b/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/extension/interactor/InstallExtension.kt @@ -10,7 +10,6 @@ import ca.gosyer.jui.domain.extension.model.Extension import ca.gosyer.jui.domain.extension.service.ExtensionRepository import kotlinx.coroutines.flow.catch import kotlinx.coroutines.flow.collect -import kotlinx.coroutines.flow.singleOrNull import me.tatarka.inject.annotations.Inject import org.lighthousegames.logging.logging diff --git a/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/settings/interactor/AboutServer.kt b/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/settings/interactor/AboutServer.kt index dba1d029..4418c929 100644 --- a/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/settings/interactor/AboutServer.kt +++ b/domain/src/commonMain/kotlin/ca/gosyer/jui/domain/settings/interactor/AboutServer.kt @@ -7,9 +7,7 @@ package ca.gosyer.jui.domain.settings.interactor import ca.gosyer.jui.domain.settings.service.SettingsRepository -import ca.gosyer.jui.domain.updates.service.UpdatesRepository import kotlinx.coroutines.flow.catch -import kotlinx.coroutines.flow.collect import kotlinx.coroutines.flow.singleOrNull import me.tatarka.inject.annotations.Inject import org.lighthousegames.logging.logging diff --git a/presentation/src/commonMain/kotlin/ca/gosyer/jui/ui/reader/loader/TachideskPageLoader.kt b/presentation/src/commonMain/kotlin/ca/gosyer/jui/ui/reader/loader/TachideskPageLoader.kt index df3626e4..ffa74609 100644 --- a/presentation/src/commonMain/kotlin/ca/gosyer/jui/ui/reader/loader/TachideskPageLoader.kt +++ b/presentation/src/commonMain/kotlin/ca/gosyer/jui/ui/reader/loader/TachideskPageLoader.kt @@ -64,10 +64,10 @@ class TachideskPageLoader( log.debug { "Loading page ${page.index}" } if (page.status.value == ReaderPage.Status.QUEUE) { getChapterPage.asFlow(chapter.chapter, page.index) { - onDownload { bytesSentTotal, contentLength -> - page.progress.value = (bytesSentTotal.toFloat() / contentLength).coerceAtMost(1.0F) - } + onDownload { bytesSentTotal, contentLength -> + page.progress.value = (bytesSentTotal.toFloat() / contentLength).coerceAtMost(1.0F) } + } .onEach { page.bitmap.value = it.toImageBitmap() page.status.value = ReaderPage.Status.READY diff --git a/presentation/src/commonMain/kotlin/ca/gosyer/jui/ui/updates/UpdatesScreenViewModel.kt b/presentation/src/commonMain/kotlin/ca/gosyer/jui/ui/updates/UpdatesScreenViewModel.kt index 1ee519e5..5006cb8f 100644 --- a/presentation/src/commonMain/kotlin/ca/gosyer/jui/ui/updates/UpdatesScreenViewModel.kt +++ b/presentation/src/commonMain/kotlin/ca/gosyer/jui/ui/updates/UpdatesScreenViewModel.kt @@ -130,7 +130,7 @@ class UpdatesScreenViewModel @Inject constructor( .firstNotNullOfOrNull { (_, chapters) -> chapters.find { it.chapter.mangaId == chapter.mangaId && - it.chapter.index == chapter.index + it.chapter.index == chapter.index } } ?.deleteDownload(deleteChapterDownload) @@ -143,7 +143,7 @@ class UpdatesScreenViewModel @Inject constructor( .firstNotNullOfOrNull { (_, chapters) -> chapters.find { it.chapter.mangaId == chapter.mangaId && - it.chapter.index == chapter.index + it.chapter.index == chapter.index } } ?.stopDownloading(stopChapterDownload)