summaryrefslogtreecommitdiffstats
path: root/zellij-utils
diff options
context:
space:
mode:
authora-kenji <aks.kenji@protonmail.com>2021-07-23 17:25:05 +0200
committera-kenji <aks.kenji@protonmail.com>2021-07-23 17:25:05 +0200
commitf323880fb7129cd74b9d156e9688fac9654480b5 (patch)
treefcd72db77fa198bb5c74503a0a07e17f1222e3f5 /zellij-utils
parent485339c58471664915776272f397e09c9a911d01 (diff)
!fixup cargo fmt
Diffstat (limited to 'zellij-utils')
-rw-r--r--zellij-utils/src/input/layout.rs16
-rw-r--r--zellij-utils/src/input/unit/layout_test.rs6
2 files changed, 11 insertions, 11 deletions
diff --git a/zellij-utils/src/input/layout.rs b/zellij-utils/src/input/layout.rs
index 713605e9c..26d967646 100644
--- a/zellij-utils/src/input/layout.rs
+++ b/zellij-utils/src/input/layout.rs
@@ -258,14 +258,14 @@ impl Layout {
post_tab = true;
// Leaf
} else if post_tab {
- if curr_post_layout.is_empty() {
- let mut part_no_tab = part.clone();
- part_no_tab.tabs.clear();
- part_no_tab.parts.clear();
- post_tab_layout.push(part_no_tab);
- } else {
- post_tab_layout.append(&mut curr_post_layout);
- }
+ if curr_post_layout.is_empty() {
+ let mut part_no_tab = part.clone();
+ part_no_tab.tabs.clear();
+ part_no_tab.parts.clear();
+ post_tab_layout.push(part_no_tab);
+ } else {
+ post_tab_layout.append(&mut curr_post_layout);
+ }
}
}
(pre_tab_layout, post_tab_layout, tabs)
diff --git a/zellij-utils/src/input/unit/layout_test.rs b/zellij-utils/src/input/unit/layout_test.rs
index 95de356cc..89217e04e 100644
--- a/zellij-utils/src/input/unit/layout_test.rs
+++ b/zellij-utils/src/input/unit/layout_test.rs
@@ -532,7 +532,7 @@ fn no_tabs_specified_should_panic() {
// TODO Make error out of this
// Only untill #631 is fixed
fn multiple_tabs_specified_should_panic() {
-let path = layout_test_dir("multiple-tabs-should-panic.yaml".into());
-let layout = Layout::new(&path);
-let _main_layout = layout.unwrap().construct_main_layout();
+ let path = layout_test_dir("multiple-tabs-should-panic.yaml".into());
+ let layout = Layout::new(&path);
+ let _main_layout = layout.unwrap().construct_main_layout();
}