onUserJoined method

void onUserJoined(
  1. int remoteUid
)

Implementation

void onUserJoined(int remoteUid) async {
  ChatCallKitUserMapper? mapper = await updateUserMapper(remoteUid);
  if (_chat.model.curCall != null) {
    if (_chat.model.curCall?.callType == ChatCallKitCallType.multi) {
      mapper?.infoMapper.forEach((key, value) {
        _chat.callTimerDic.remove(value)?.cancel();
      });
    } else {
      _chat.callTimerDic
          .remove(_chat.model.curCall!.remoteUserAccount)
          ?.cancel();
    }

    for (var value in handlers) {
      value.onUserJoined.call(remoteUid, mapper?.infoMapper[remoteUid]);
    }
  }
}