diff options
| author | Sagittarius-a <sagittarius-a@users.noreply.github.com> | 2021-08-03 22:16:40 +0200 |
|---|---|---|
| committer | Sagittarius-a <sagittarius-a@users.noreply.github.com> | 2021-08-03 22:16:40 +0200 |
| commit | 24ef96b96510d3efba78a965364bab992a8a92fb (patch) | |
| tree | 89b5dd9a55700f5276a0a5418f99d1c0bc6de472 | |
| parent | store tab history in a stack-like data structure (diff) | |
| download | sl0ppij-24ef96b96510d3efba78a965364bab992a8a92fb.tar.gz sl0ppij-24ef96b96510d3efba78a965364bab992a8a92fb.tar.xz sl0ppij-24ef96b96510d3efba78a965364bab992a8a92fb.zip | |
fix cargo clippy lint
| -rw-r--r-- | zellij-server/src/screen.rs | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/zellij-server/src/screen.rs b/zellij-server/src/screen.rs index ef5a4d5a..c6c0f3a8 100644 --- a/zellij-server/src/screen.rs +++ b/zellij-server/src/screen.rs @@ -342,9 +342,7 @@ impl Screen { /// Consumes the last entry in tab history. pub fn get_previous_tab(&mut self) -> Option<&Tab> { let last = self.tab_history.pop(); - if last.is_none() { - return None; - } + last?; match last.unwrap() { Some(tab) => self.tabs.get(&tab), None => None, |
