diff --git a/cove-tui/src/chat/tree.rs b/cove-tui/src/chat/tree.rs index a998183..a2ddb36 100644 --- a/cove-tui/src/chat/tree.rs +++ b/cove-tui/src/chat/tree.rs @@ -48,7 +48,7 @@ struct MsgBlock { } impl MsgBlock { - fn to_block(self, id: I, indent: usize) -> Block { + fn into_block(self, id: I, indent: usize) -> Block { Block { line: 0, height: self.lines.len() as i32, @@ -151,13 +151,13 @@ impl Layout { } fn prepend(&mut self, mut layout: Self) { - while let Some(mut block) = layout.blocks.pop_back() { + while let Some(block) = layout.blocks.pop_back() { self.push_front(block); } } fn append(&mut self, mut layout: Self) { - while let Some(mut block) = layout.blocks.pop_front() { + while let Some(block) = layout.blocks.pop_front() { self.push_back(block); } } @@ -197,7 +197,7 @@ impl TreeView { nick, lines, } - .to_block(msg.id(), indent) + .into_block(msg.id(), indent) } fn layout_subtree(