Implement disconnect specific client ID
This commit is contained in:
@@ -138,7 +138,10 @@ pub async fn home(
|
||||
config.clients.retain(|c| c.id != delete_client_id);
|
||||
config.save().await?;
|
||||
success_message = Some("The client was successfully deleted!".to_string());
|
||||
// TODO : close connections with given id
|
||||
|
||||
if let Err(e) = tx.send(WsMessage::CloseClientSession(delete_client_id)) {
|
||||
log::error!("Failed to send CloseClientSession: {}", e);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user