onCallSelectAnswer method

Future<void> onCallSelectAnswer(
  1. Room room,
  2. Map<String, dynamic> content
)

Implementation

Future<void> onCallSelectAnswer(
    Room room, Map<String, dynamic> content) async {
  final String callId = content['call_id'];
  Logs().d('SelectAnswer received for call ID $callId');
  final String selectedPartyId = content['selected_party_id'];

  final call = calls[VoipId(roomId: room.id, callId: callId)];
  if (call != null) {
    if (call.room.id != room.id) {
      Logs().w(
          'Ignoring call select answer for room ${room.id} claiming to be for call in room ${call.room.id}');
      return;
    }
    await call.onSelectAnswerReceived(selectedPartyId);
  }
}