Skip to content

Commit

Permalink
refactor: use rust pattern alternative operator
Browse files Browse the repository at this point in the history
refactor: use rust pattern
  • Loading branch information
Shourai committed Jan 21, 2025
1 parent 325ebb2 commit 603c8b4
Showing 1 changed file with 2 additions and 10 deletions.
12 changes: 2 additions & 10 deletions src/ui.rs
Original file line number Diff line number Diff line change
Expand Up @@ -253,19 +253,11 @@ impl App {

match key.code {
Char('c') => AppKeyAction::Stop,
Char('j') => {
Char('j' | 'n') => {
self.next();
AppKeyAction::Ok
}
Char('k') => {
self.previous();
AppKeyAction::Ok
}
Char('n') => {
self.next();
AppKeyAction::Ok
}
Char('p') => {
Char('k' | 'p') => {
self.previous();
AppKeyAction::Ok
}
Expand Down

0 comments on commit 603c8b4

Please sign in to comment.