Leaks ;3 fixed

This commit is contained in:
Shiroyasha 2024-05-26 03:21:25 +03:00
parent c0c7245f03
commit b435d9e420
Signed by: shiroyashik
GPG key ID: E4953D3940D7860A
2 changed files with 18 additions and 8 deletions

View file

@ -68,6 +68,10 @@ impl Authenticated {
pub fn contains_token(&self, token: &String) -> bool {
self.user_data.contains_key(token)
}
pub fn remove(&self, uuid: &Uuid) {
let token = self.uuid.remove(uuid).unwrap().1;
self.user_data.remove(&token);
}
}
#[derive(Debug, Clone)]