aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authora-kenji <aks.kenji@protonmail.com>2021-02-18 21:46:16 +0100
committera-kenji <aks.kenji@protonmail.com>2021-02-20 20:22:34 +0100
commit6bb419661e2d324bcafe7bb2b84608e0c98adf4c (patch)
treef055fd0a2342ea189a989047fdba99975b93b4af /src
parentfix(clippy): unneeded `return` statement (diff)
downloadsl0ppij-6bb419661e2d324bcafe7bb2b84608e0c98adf4c.tar.gz
sl0ppij-6bb419661e2d324bcafe7bb2b84608e0c98adf4c.tar.xz
sl0ppij-6bb419661e2d324bcafe7bb2b84608e0c98adf4c.zip
fix(clippy): use of `unwrap_or` followed by a fn
use of `unwrap_or` followed by a function call
Diffstat (limited to 'src')
-rw-r--r--src/common/input/keybinds.rs2
1 files changed, 1 insertions, 1 deletions
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);
}