diff --git a/src/protocols/commands/disconnect.rs b/src/protocols/commands/disconnect.rs index 7bd966c..7242985 100644 --- a/src/protocols/commands/disconnect.rs +++ b/src/protocols/commands/disconnect.rs @@ -4,7 +4,7 @@ use std::sync::Mutex; use std::sync::Arc; use std::collections::HashMap; -pub fn remove_client(clients_ref: &Arc>>, uuid: &String){ +pub fn remove_client(clients_ref: &Arc>>, uuid: &String) -> Client{ let mut clients_hashmap = clients_ref.lock().unwrap(); - clients_hashmap.remove(uuid); + clients_hashmap.remove(uuid).unwrap() }