From 054948f4b8eaaafbe6dc22f46198a2c4402e69d8 Mon Sep 17 00:00:00 2001 From: Tommy Volk Date: Wed, 2 Oct 2024 10:24:27 -0500 Subject: [PATCH] chore: fix clippy warnings --- fedimint-server/src/config/api.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fedimint-server/src/config/api.rs b/fedimint-server/src/config/api.rs index 6c14bdaca0a..47093b5e8de 100644 --- a/fedimint-server/src/config/api.rs +++ b/fedimint-server/src/config/api.rs @@ -499,7 +499,7 @@ impl ConfigGenApi { self.bitcoin_status_cache.read().await; if let Some((timestamp, status)) = cached_status.as_ref() { if timestamp.elapsed() < self.bitcoin_status_cache_duration { - return Ok(status.clone()); + return Ok(*status); } } } @@ -520,7 +520,7 @@ impl ConfigGenApi { // Update the bitcoin status cache let mut cached_status: RwLockWriteGuard<'_, Option<(Instant, BitcoinRpcConnectionStatus)>> = self.bitcoin_status_cache.write().await; - *cached_status = Some((Instant::now(), status.clone())); + *cached_status = Some((Instant::now(), status)); Ok(status) }