Skip to content

Commit 4737ae2

Browse files
Copilotkarthiknadig
andcommitted
Remove unnecessary clone in find_executables call
find_executables accepts T: AsRef<Path>, so we can pass the reference directly without cloning Co-authored-by: karthiknadig <[email protected]>
1 parent 49c5046 commit 4737ae2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

crates/pet/src/find.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -370,7 +370,7 @@ fn find_python_environments_in_paths_with_locators(
370370
} else {
371371
// Paths like /Library/Frameworks/Python.framework/Versions/3.10/bin can end up in the current PATH variable.
372372
// Hence do not just look for files in a bin directory of the path.
373-
find_executables(path.clone())
373+
find_executables(path)
374374
.into_iter()
375375
.filter(|p| {
376376
// Exclude python2 on macOS

0 commit comments

Comments
 (0)