Skip to content
This repository was archived by the owner on Sep 17, 2023. It is now read-only.

Commit 5fb9aed

Browse files
committed
refactor: use into_iter
to convey that we want to move ownership here. Ticket: 0
1 parent 568cc7f commit 5fb9aed

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/link.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ fn key_children_by_parent(
1919
package_manifest: &PackageManifest,
2020
) -> HashMap<PathBuf, Vec<String>> {
2121
let mut path_so_far = PathBuf::new();
22-
for component in package_manifest.directory().iter() {
22+
for component in package_manifest.directory().into_iter() {
2323
let children = accumulator.entry(path_so_far.clone()).or_default();
2424

2525
let new_child = component
@@ -30,7 +30,7 @@ fn key_children_by_parent(
3030
children.push(new_child);
3131
}
3232

33-
path_so_far.push(&component);
33+
path_so_far.push(component);
3434
}
3535
accumulator
3636
}

0 commit comments

Comments
 (0)