onTransportConnect method

void onTransportConnect(
  1. Transport transport
)

Implementation

void onTransportConnect(Transport transport) async {
  logger.debug('Transport connected');
  if (_status == C.STATUS_USER_CLOSED) {
    return;
  }
  _status = C.STATUS_READY;

  emit(EventSocketConnected(socket: transport.socket));

  if (_dynConfiguration!.register!) {
    await Future.delayed(Duration(milliseconds: 200));
    _registrator.register();
  }
}