Compare commits
1 Commits
main
...
c48c71b56b
| Author | SHA1 | Date | |
|---|---|---|---|
|
c48c71b56b
|
@@ -46,14 +46,7 @@ mod server_only {
|
|||||||
let mut disconnected_client_ids = HashSet::new();
|
let mut disconnected_client_ids = HashSet::new();
|
||||||
let subscribed_clients = SUBSCRIBED_CLIENTS.read().await;
|
let subscribed_clients = SUBSCRIBED_CLIENTS.read().await;
|
||||||
for (id, client) in subscribed_clients.iter() {
|
for (id, client) in subscribed_clients.iter() {
|
||||||
if client
|
if client.websocket.lock().await.send(UpdateEvent).await.is_err() {
|
||||||
.websocket
|
|
||||||
.lock()
|
|
||||||
.await
|
|
||||||
.send(UpdateEvent)
|
|
||||||
.await
|
|
||||||
.is_err()
|
|
||||||
{
|
|
||||||
disconnected_client_ids.insert(*id);
|
disconnected_client_ids.insert(*id);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user