fix reconnection logic
This commit is contained in:
@@ -125,7 +125,8 @@ class StreamChatCoreState extends State<StreamChatCore>
|
|||||||
_isConnectionAvailable = result != ConnectivityResult.none;
|
_isConnectionAvailable = result != ConnectivityResult.none;
|
||||||
if (!_isInForeground) return;
|
if (!_isInForeground) return;
|
||||||
if (_isConnectionAvailable) {
|
if (_isConnectionAvailable) {
|
||||||
if (client.wsConnectionStatus == ConnectionStatus.disconnected) {
|
if (client.wsConnectionStatus == ConnectionStatus.disconnected &&
|
||||||
|
user != null) {
|
||||||
client.openConnection();
|
client.openConnection();
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
|
|||||||
Reference in New Issue
Block a user