clippy fix

This commit is contained in:
Stephan Dilly 2020-04-13 01:38:13 +02:00
parent b0b1f7d86b
commit 99a240da5f

View File

@ -489,7 +489,9 @@ impl App {
}
fn switch_focus(&mut self, f: Focus) -> NeedsUpdate {
if self.focus != f {
if self.focus == f {
NeedsUpdate::empty()
} else {
self.focus = f;
match self.focus {
@ -510,8 +512,6 @@ impl App {
};
NeedsUpdate::DIFF | NeedsUpdate::COMMANDS
} else {
NeedsUpdate::empty()
}
}