clean references

This commit is contained in:
Alex Janka 2024-10-30 08:56:02 +11:00
parent b43c6c9c56
commit cca92edd65

View file

@ -138,10 +138,10 @@ async fn main() -> Res<()> {
if parent.node_type == swayipc_async::NodeType::Workspace { if parent.node_type == swayipc_async::NodeType::Workspace {
break 'ws parent.name.clone(); break 'ws parent.name.clone();
} }
last_node = &parent; last_node = parent;
}; };
if !v.is_some_and(|w| w.eq_ignore_ascii_case(&workspace)) { if !v.is_some_and(|w| w.eq_ignore_ascii_case(workspace)) {
// only run the command if we're on a different workspace // only run the command if we're on a different workspace
command_connection command_connection
.run_command(format!("move container to workspace {workspace}")) .run_command(format!("move container to workspace {workspace}"))
@ -225,7 +225,7 @@ async fn autosplit(
} }
// don't autosplit if we're in fullscreen // don't autosplit if we're in fullscreen
if any_parent(&tree, node.id, |n| { if any_parent(tree, node.id, |n| {
(n.node_type == swayipc_async::NodeType::Con (n.node_type == swayipc_async::NodeType::Con
|| n.node_type == swayipc_async::NodeType::FloatingCon) || n.node_type == swayipc_async::NodeType::FloatingCon)
&& n.fullscreen_mode.is_some_and(|m| m != 0) && n.fullscreen_mode.is_some_and(|m| m != 0)