disconnect method
Implementation
Future<void> disconnect([int? code, String? reason]) async {
_intentionalDisconnect = true;
_log('Disconnecting WebSocket');
_heartbeatManager.stop();
_reconnectionManager.stopReconnection();
await _adapter.disconnect(code, reason);
}