Skip to content

Commit

Permalink
refactor: 2 clippy warnings (topgrade-rs#789)
Browse files Browse the repository at this point in the history
  • Loading branch information
SteveLauC authored May 6, 2024
1 parent a3428e3 commit 767f0d9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -488,7 +488,7 @@ impl ConfigFile {
for path in possible_config_paths.iter() {
if path.exists() {
debug!("Configuration at {}", path.display());
res.0 = path.clone();
res.0.clone_from(path);
break;
}
}
Expand All @@ -497,7 +497,7 @@ impl ConfigFile {

// If no config file exists, create a default one in the config directory
if !res.0.exists() && res.1.is_empty() {
res.0 = possible_config_paths[0].clone();
res.0.clone_from(&possible_config_paths[0]);
debug!("No configuration exists");
write(&res.0, EXAMPLE_CONFIG).map_err(|e| {
debug!(
Expand Down

0 comments on commit 767f0d9

Please sign in to comment.