Do not attempt to reconnect to cloud when username is changed to empty string

This commit is contained in:
Thomas Weber committed 2021-01-12 21:32:14 -06:00
1 parent a97c12682f
commit 98ec0194a7
1 file changed
+3 -1
+3 -1
View File
@@ -55,7 +55,9 @@ const cloudManagerHOC = function (WrappedComponent) {
// tw: handle cases where we should explicitly close and reconnect() in the same update
if (this.shouldReconnect(this.props, prevProps)) {
this.disconnectFromCloud();
this.connectToCloud();
if (this.shouldConnect(this.props)) {
this.connectToCloud();
}
return;
}