aboutsummaryrefslogtreecommitdiff
path: root/src/rpc/system.rs
diff options
context:
space:
mode:
authorAlex Auvolat <alex@adnab.me>2023-01-26 17:26:32 +0100
committerAlex Auvolat <alex@adnab.me>2023-01-26 17:26:32 +0100
commit8e93d6997415d60ba5c371da8b27065a57254a8c (patch)
tree8bf3c182ca5d70bd242cc691d2b1fee65c8b6cd3 /src/rpc/system.rs
parent3113f6b5f2a688a3f7c4f933774866f48618f7d1 (diff)
downloadgarage-8e93d6997415d60ba5c371da8b27065a57254a8c.tar.gz
garage-8e93d6997415d60ba5c371da8b27065a57254a8c.zip
More clippy fixes
Diffstat (limited to 'src/rpc/system.rs')
-rw-r--r--src/rpc/system.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/rpc/system.rs b/src/rpc/system.rs
index e0ced8cc..b42e49fc 100644
--- a/src/rpc/system.rs
+++ b/src/rpc/system.rs
@@ -215,7 +215,7 @@ pub fn gen_node_key(metadata_dir: &Path) -> Result<NodeKey, Error> {
} else {
if !metadata_dir.exists() {
info!("Metadata directory does not exist, creating it.");
- std::fs::create_dir(&metadata_dir)?;
+ std::fs::create_dir(metadata_dir)?;
}
info!("Generating new node key pair.");
@@ -419,7 +419,7 @@ impl System {
.get(&n.id.into())
.cloned()
.map(|(_, st)| st)
- .unwrap_or(NodeStatus::unknown()),
+ .unwrap_or_else(NodeStatus::unknown),
})
.collect::<Vec<_>>();
known_nodes