equal
deleted
inserted
replaced
254 pub fn is_admin(&self, client_id: ClientId) -> bool { |
254 pub fn is_admin(&self, client_id: ClientId) -> bool { |
255 self.clients |
255 self.clients |
256 .get(client_id) |
256 .get(client_id) |
257 .map(|c| c.is_admin()) |
257 .map(|c| c.is_admin()) |
258 .unwrap_or(false) |
258 .unwrap_or(false) |
|
259 } |
|
260 |
|
261 #[inline] |
|
262 pub fn is_checker(&self, client_id: ClientId) -> bool { |
|
263 self.checkers.contains(client_id) |
259 } |
264 } |
260 |
265 |
261 pub fn add_client(&mut self, client_id: ClientId, data: HwAnteroomClient) { |
266 pub fn add_client(&mut self, client_id: ClientId, data: HwAnteroomClient) { |
262 if data.is_checker { |
267 if data.is_checker { |
263 self.checkers.insert(client_id, HwChecker::new(client_id)); |
268 self.checkers.insert(client_id, HwChecker::new(client_id)); |