Skip to content

Commit

Permalink
merged_tree: avoid two unnecessary clones
Browse files Browse the repository at this point in the history
  • Loading branch information
martinvonz committed Nov 28, 2024
1 parent bf17067 commit b9e9392
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/src/merged_tree.rs
Original file line number Diff line number Diff line change
Expand Up @@ -211,7 +211,7 @@ impl MergedTree {
}
_ => {
let subdir = self.dir().join(name);
Ok(Tree::empty(self.store().clone(), subdir.clone()))
Ok(Tree::empty(self.store().clone(), subdir))
}
})?;
Ok(Some(MergedTree { trees }))
Expand Down Expand Up @@ -961,7 +961,7 @@ impl<'matcher> TreeDiffStreamImpl<'matcher> {
.await?;
builder.build()
} else {
Merge::resolved(Tree::empty(store, dir.clone()))
Merge::resolved(Tree::empty(store, dir))
};
Ok(MergedTree { trees })
}
Expand Down

0 comments on commit b9e9392

Please sign in to comment.