Fix download status not updated properly after starting batch download (#7561)
(cherry picked from commit 473dc688f0bbb9732e3d75d137bc7025418d9bcf)
This commit is contained in:
parent
c69f53a8f4
commit
8bd7f95afc
@ -826,7 +826,7 @@ class MangaPresenter(
|
||||
downloadManager.queue.getStatusAsFlow()
|
||||
.filter { /* SY --> */ if (isMergedSource) it.manga.id in mergedIds else /* SY <-- */ it.manga.id == successState?.manga?.id }
|
||||
.catch { error -> logcat(LogPriority.ERROR, error) }
|
||||
.collectLatest {
|
||||
.collect {
|
||||
withUIContext {
|
||||
updateDownloadState(it)
|
||||
}
|
||||
@ -838,7 +838,7 @@ class MangaPresenter(
|
||||
downloadManager.queue.getProgressAsFlow()
|
||||
.filter { /* SY --> */ if (isMergedSource) it.manga.id in mergedIds else /* SY <-- */ it.manga.id == successState?.manga?.id }
|
||||
.catch { error -> logcat(LogPriority.ERROR, error) }
|
||||
.collectLatest {
|
||||
.collect {
|
||||
withUIContext {
|
||||
updateDownloadState(it)
|
||||
}
|
||||
|
@ -159,7 +159,7 @@ class UpdatesPresenter(
|
||||
observeDownloadsStatusJob = presenterScope.launchIO {
|
||||
downloadManager.queue.getStatusAsFlow()
|
||||
.catch { error -> logcat(LogPriority.ERROR, error) }
|
||||
.collectLatest {
|
||||
.collect {
|
||||
withUIContext {
|
||||
updateDownloadState(it)
|
||||
}
|
||||
@ -170,7 +170,7 @@ class UpdatesPresenter(
|
||||
observeDownloadsPageJob = presenterScope.launchIO {
|
||||
downloadManager.queue.getProgressAsFlow()
|
||||
.catch { error -> logcat(LogPriority.ERROR, error) }
|
||||
.collectLatest {
|
||||
.collect {
|
||||
withUIContext {
|
||||
updateDownloadState(it)
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user