This commit is contained in:
Antonio Scandurra
2023-10-22 16:53:59 +02:00
parent 5d10dc7e58
commit 50bbdd5cab
5 changed files with 107 additions and 10 deletions
+1 -1
View File
@@ -19,7 +19,7 @@ util = { path = "../util" }
rpc = { path = "../rpc" }
text = { path = "../text" }
settings2 = { path = "../settings2" }
feature_flags = { path = "../feature_flags" }
feature_flags2 = { path = "../feature_flags2" }
sum_tree = { path = "../sum_tree" }
anyhow.workspace = true
+6 -8
View File
@@ -193,16 +193,14 @@ impl UserStore {
}
Status::SignedOut => {
current_user_tx.send(None).await.ok();
if let Some(this) = this.upgrade(&cx) {
this.update(&mut cx, |this, cx| {
cx.notify();
this.clear_contacts()
})
.await;
}
this.update(&mut cx, |this, cx| {
cx.notify();
this.clear_contacts()
})
.await;
}
Status::ConnectionLost => {
if let Some(this) = this.upgrade(&cx) {
if let Some(this) = this.upgrade() {
this.update(&mut cx, |this, cx| {
cx.notify();
this.clear_contacts()