refact: use clone instead to_owned

This commit is contained in:
steven-omaha
2023-06-02 14:05:17 +02:00
parent 1022db2d48
commit a573cd18f8
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -364,7 +364,7 @@ impl Pacdef {
for name in new_groups {
ensure!(
*name != "." && *name != "..",
crate::Error::InvalidGroupName(name.to_owned())
crate::Error::InvalidGroupName(name.clone())
);
}
+1 -1
View File
@@ -50,7 +50,7 @@ impl Group {
if path.is_dir() {
if warn_not_symlinks && path.is_symlink() {
symlink_dirs.push(path.to_owned());
symlink_dirs.push(path);
}
continue;
}