mirror of
https://github.com/vector-im/riotX-android
synced 2025-10-05 15:52:47 +02:00
Ensure Background sync is not stopped when there is an active call, even when the app goes to background.
This commit is contained in:
@@ -189,11 +189,15 @@ class VectorApplication :
|
||||
fcmHelper.onEnterBackground(activeSessionHolder)
|
||||
|
||||
if (stopBackgroundSync) {
|
||||
Timber.i("App entered background: stop any background sync")
|
||||
activeSessionHolder.getSafeActiveSessionAsync {
|
||||
it?.syncService()?.stopAnyBackgroundSync()
|
||||
if (webRtcCallManager.currentCall.get() == null) {
|
||||
Timber.i("App entered background: stop any background sync")
|
||||
activeSessionHolder.getSafeActiveSessionAsync {
|
||||
it?.syncService()?.stopAnyBackgroundSync()
|
||||
}
|
||||
stopBackgroundSync = false
|
||||
} else {
|
||||
Timber.i("App entered background: there is an active call do not stop background sync")
|
||||
}
|
||||
stopBackgroundSync = false
|
||||
}
|
||||
}
|
||||
})
|
||||
|
Reference in New Issue
Block a user