Fix ConferenceParticipantDeviceData not updated in certain circonstances

This commit is contained in:
Christophe Deschamps 2022-12-02 16:14:11 +01:00
parent 61e645c238
commit 6365c66d55

View file

@ -73,7 +73,7 @@ class VoipConferenceActiveSpeakerView: UIView, UICollectionViewDataSource, UICol
duration.conference = model.conference.value
self.remotelyRecording.isRemotelyRecorded = model.isRemotelyRecorded
model.conferenceParticipantDevices.readCurrentAndObserve { value in
model.activeSpeakerConferenceParticipantDevices.value = Array((value!.dropFirst()))
model.activeSpeakerConferenceParticipantDevices.value = Array((value!.dropFirst().filter { !$0.isMe } ))
}
model.activeSpeakerConferenceParticipantDevices.readCurrentAndObserve { (_) in
self.reloadData()
@ -192,9 +192,6 @@ class VoipConferenceActiveSpeakerView: UIView, UICollectionViewDataSource, UICol
}
func reloadData() {
conferenceViewModel?.activeSpeakerConferenceParticipantDevices.value?.forEach {
$0.clearObservers()
}
self.grid.reloadData()
self.meGrid.reloadData()
}