VoiceBroadcast: Manage app crash cases when recording (#7188)

* Cancel automatically a Voice Broadcast from a room after an app crash
* We limit for the moment the uncompleted voice broadcast cleaning to the breadcrumbs rooms list

By considering potential performance issues, we decided to limit the uncompleted VB cleaning in the recents list service:
- we run the process only once when the application is resumed
- we run the process only on the breadcrumbs rooms list

This prevent us from checking several times in parallel the same room (because a room may be listed in several recents sections)
This prevent us from checking several times the same room (each room should be checked only once after the app resume)
If a room is not checked from the recents list, a sanity check is still done in RoomViewController (to clean the room when the user opens it)
This commit is contained in:
Phl-Pro
2022-12-23 15:25:52 +01:00
committed by GitHub
parent ff075c7052
commit 746391ae23
8 changed files with 107 additions and 5 deletions
@@ -316,3 +316,10 @@ extension RoomViewController: ComposerLinkActionBridgePresenterDelegate {
composerLinkActionBridgePresenter = nil
}
}
// MARK: - VoiceBroadcast
extension RoomViewController {
@objc func stopUncompletedVoiceBroadcastIfNeeded() {
self.roomDataSource.room.stopUncompletedVoiceBroadcastIfNeeded()
}
}