File tree Expand file tree Collapse file tree 1 file changed +5
-0
lines changed
appnav/src/main/kotlin/io/element/android/appnav Expand file tree Collapse file tree 1 file changed +5
-0
lines changed Original file line number Diff line number Diff line change @@ -88,6 +88,7 @@ import kotlinx.coroutines.flow.combine
8888import kotlinx.coroutines.flow.debounce
8989import kotlinx.coroutines.flow.launchIn
9090import kotlinx.coroutines.flow.onEach
91+ import kotlinx.coroutines.flow.onStart
9192import kotlinx.coroutines.launch
9293import kotlinx.parcelize.Parcelize
9394import timber.log.Timber
@@ -196,6 +197,10 @@ class LoggedInFlowNode @AssistedInject constructor(
196197 ) { syncState, networkStatus ->
197198 Pair (syncState, networkStatus)
198199 }
200+ .onStart {
201+ // Temporary fix to ensure that the sync is started even if the networkStatus is offline.
202+ syncService.startSync()
203+ }
199204 .collect { (syncState, networkStatus) ->
200205 Timber .d(" Sync state: $syncState , network status: $networkStatus " )
201206 if (syncState != SyncState .Running && networkStatus == NetworkStatus .Online ) {
You can’t perform that action at this time.
0 commit comments