fix rust fmt
This commit is contained in:
1 parent
63061d7797
commit
6d97010c40
2 files changed
+10
-8
No files matched your search
@@ -103,10 +103,11 @@ impl LineEditorHost for LuaReplHost {
|
||||
) -> Option<Action> {
|
||||
let (line, _cursor) = editor.get_line_and_cursor();
|
||||
match event {
|
||||
InputEvent::Key(KeyEvent { key: KeyCode::Escape, .. }) => {
|
||||
line.is_empty().then_some(Action::Cancel)
|
||||
}
|
||||
_ => None
|
||||
InputEvent::Key(KeyEvent {
|
||||
key: KeyCode::Escape,
|
||||
..
|
||||
}) => line.is_empty().then_some(Action::Cancel),
|
||||
_ => None,
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -32,10 +32,11 @@ impl LineEditorHost for PromptHost {
|
||||
) -> Option<Action> {
|
||||
let (line, _cursor) = editor.get_line_and_cursor();
|
||||
match event {
|
||||
InputEvent::Key(KeyEvent { key: KeyCode::Escape, .. }) => {
|
||||
line.is_empty().then_some(Action::Cancel)
|
||||
}
|
||||
_ => None
|
||||
InputEvent::Key(KeyEvent {
|
||||
key: KeyCode::Escape,
|
||||
..
|
||||
}) => line.is_empty().then_some(Action::Cancel),
|
||||
_ => None,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user