Fix clippy warnings (#2108)

* Fix clippy warnings

* review feedback.
This commit is contained in:
Lucas Kent 2022-01-01 13:00:11 +11:00 committed by GitHub
parent 438d286fd5
commit 0b39024133
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
23 changed files with 105 additions and 127 deletions

View file

@ -151,7 +151,7 @@ impl ModifierKeyState {
pub fn key_release(&mut self, keycode: ffi::KeyCode) {
if let Some(modifier) = self.keys.remove(&keycode) {
if self.keys.values().find(|&&m| m == modifier).is_none() {
if !self.keys.values().any(|&m| m == modifier) {
set_modifier(&mut self.state, modifier, false);
}
}