Clippy easy wins 1 (#596)

This commit is contained in:
trevyn
2021-03-17 10:51:53 -04:00
committed by GitHub
parent 4e4880be8e
commit a88a522f84
6 changed files with 13 additions and 40 deletions
+4 -8
View File
@@ -951,14 +951,10 @@ where
// for backwards compatibility: If tor config doesn't exist in the file, assume
// the top level directory for data
let tor_config = match tor_config {
Some(tc) => tc,
None => {
let mut tc = TorConfig::default();
tc.send_config_dir = wallet_config.data_file_dir.clone();
tc
}
};
let tor_config = tor_config.unwrap_or_else(|| TorConfig {
send_config_dir: wallet_config.data_file_dir.clone(),
..Default::default()
});
// Instantiate wallet (doesn't open the wallet)
let wallet =