Fix clippy suggestions

This commit is contained in:
David Peter authored and David Peter committed 2023-03-15 10:13:58 +01:00
1 parent b38bfc894c
commit c44aa1d006
3 files changed
+13 -13

No files matched your search

+2 -2
View File
@@ -131,7 +131,7 @@ impl CommandInputPolicy {
CommandInputPolicy::Null => Stdio::null(),
CommandInputPolicy::File(path) => {
let file: File = File::open(&path)?;
let file: File = File::open(path)?;
Stdio::from(file)
}
};
@@ -171,7 +171,7 @@ impl CommandOutputPolicy {
CommandOutputPolicy::Pipe => (Stdio::piped(), Stdio::null()),
CommandOutputPolicy::File(path) => {
let file = File::create(&path)?;
let file = File::create(path)?;
(file.into(), Stdio::null())
}