summaryrefslogtreecommitdiff
path: root/src/widgets
diff options
context:
space:
mode:
authorNathan Reiner <nathan@nathanreiner.xyz>2024-08-03 12:51:23 +0200
committerNathan Reiner <nathan@nathanreiner.xyz>2024-08-03 12:51:23 +0200
commitf7c16781c0d68b8a20bc5d88d0040940459b903e (patch)
tree9608515db54b6aaaf23175d24ace523e0c0c0bb5 /src/widgets
parent4d4d72587185fb485fd6826514241680fc2d02ba (diff)
add default return value to keymap
Diffstat (limited to 'src/widgets')
-rw-r--r--src/widgets/luaeditor/mod.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/widgets/luaeditor/mod.rs b/src/widgets/luaeditor/mod.rs
index 4fb8a3b..a24c6e7 100644
--- a/src/widgets/luaeditor/mod.rs
+++ b/src/widgets/luaeditor/mod.rs
@@ -34,9 +34,9 @@ impl LuaEditor {
}
pub fn handle_key_event(&mut self, event: KeyEvent) {
- let r = EditorKeyMap::handle(event);
+ let populate = EditorKeyMap::handle(event);
- if r.unwrap_or(true) {
+ if populate {
match event.code {
KeyCode::Char(c) => GlobalState::instance_mut().editor.buffer.insert(c),
KeyCode::Backspace => {