mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-11-03 16:10:20 +00:00
Reuse the existing room proxy for poll history and avoid an extra subscription
This commit is contained in:
@@ -872,17 +872,9 @@ class RoomFlowCoordinator: FlowCoordinatorProtocol {
|
||||
}
|
||||
|
||||
private func asyncPresentRoomPollsHistory(roomID: String) async {
|
||||
let roomProxy: RoomProxyProtocol
|
||||
|
||||
guard let proxy = await userSession.clientProxy.roomForIdentifier(roomID) else {
|
||||
MXLog.error("Invalid room identifier: \(roomID)")
|
||||
stateMachine.tryEvent(.dismissPollsHistory)
|
||||
return
|
||||
guard let roomProxy else {
|
||||
fatalError()
|
||||
}
|
||||
|
||||
roomProxy = proxy
|
||||
|
||||
await roomProxy.subscribeForUpdates()
|
||||
|
||||
let userID = userSession.clientProxy.userID
|
||||
|
||||
|
||||
Reference in New Issue
Block a user