diff --git a/lib/src/voip/group_call_session.dart b/lib/src/voip/group_call_session.dart index 77e5bad7..c58734e9 100644 --- a/lib/src/voip/group_call_session.dart +++ b/lib/src/voip/group_call_session.dart @@ -246,7 +246,8 @@ class GroupCallSession { if (anyJoined.isNotEmpty || anyLeft.isNotEmpty) { if (anyJoined.isNotEmpty) { - final nonLocalAnyJoined = anyJoined..remove(localParticipant); + final nonLocalAnyJoined = Set.from(anyJoined) + ..remove(localParticipant); if (nonLocalAnyJoined.isNotEmpty && state == GroupCallState.entered) { Logs().v( 'nonLocalAnyJoined: ${nonLocalAnyJoined.map((e) => e.id).toString()} roomId: ${room.id} groupCallId: $groupCallId'); @@ -255,7 +256,8 @@ class GroupCallSession { _participants.addAll(anyJoined); } if (anyLeft.isNotEmpty) { - final nonLocalAnyLeft = anyLeft..remove(localParticipant); + final nonLocalAnyLeft = Set.from(anyLeft) + ..remove(localParticipant); if (nonLocalAnyLeft.isNotEmpty && state == GroupCallState.entered) { Logs().v( 'nonLocalAnyLeft: ${nonLocalAnyLeft.map((e) => e.id).toString()} roomId: ${room.id} groupCallId: $groupCallId');