From 6bb419661e2d324bcafe7bb2b84608e0c98adf4c Mon Sep 17 00:00:00 2001 From: a-kenji Date: Thu, 18 Feb 2021 21:46:16 +0100 Subject: [PATCH] fix(clippy): use of `unwrap_or` followed by a fn use of `unwrap_or` followed by a function call --- src/common/input/keybinds.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/common/input/keybinds.rs b/src/common/input/keybinds.rs index 7197d2de..151d3495 100644 --- a/src/common/input/keybinds.rs +++ b/src/common/input/keybinds.rs @@ -172,7 +172,7 @@ pub fn key_to_actions( // FIXME in command mode, unbound keystrokes should probably do nothing instead of // writing to the terminal. Will be easier to implement after a big refactor of the // input system (@categorille) - .unwrap_or(vec![Action::Write(input)]) + .unwrap_or_else(|| vec![Action::Write(input)]) } else { unreachable!("Unrecognized mode: {:?}", mode); }