waitForConnection method

Future<PhoenixConnection> waitForConnection()

Implementation

Future<PhoenixConnection> waitForConnection() async {
  if (_conn.readyState == WebSocket.OPEN) {
    return this;
  }

  await _opened;
  return this;
}