From 0f012112270eda2f313028869738329c5b09dbb8 Mon Sep 17 00:00:00 2001 From: Red Artist Date: Wed, 24 Jan 2024 05:18:44 +0530 Subject: [PATCH] fix clippy warnings --- crates/egui_window_glfw_passthrough/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/egui_window_glfw_passthrough/src/lib.rs b/crates/egui_window_glfw_passthrough/src/lib.rs index 34e2cbe..ab46895 100644 --- a/crates/egui_window_glfw_passthrough/src/lib.rs +++ b/crates/egui_window_glfw_passthrough/src/lib.rs @@ -718,7 +718,7 @@ pub fn layout_based_glfw_to_egui_key(key: glfw::Key, scancode: i32) -> Option { let name = glfw::get_key_name(Some(key), Some(scancode)); - name.map(|n| egui::Key::from_name(&n)).flatten() + name.and_then(|n| egui::Key::from_name(&n)) } _ => layout_independent_glfw_to_egui_key(key), }