A free and open source instant messaging and VoIP chat app built for friends, groups, and communities.
fix(app-proxy): collapse the discovery cold-start retry condition (#1716)
Hampus9cb8812be0d1
diff --git a/fluxer_app_proxy/src/discovery_cache.rs b/fluxer_app_proxy/src/discovery_cache.rsindex c08780ecc..a371508b2 100644--- a/fluxer_app_proxy/src/discovery_cache.rs+++ b/fluxer_app_proxy/src/discovery_cache.rs@@ -44,10 +44,10 @@ impl DiscoveryCache {}{let mut last_attempt = self.cold_start_attempt.lock().await;- if let Some(at) = *last_attempt {- if at.elapsed() < COLD_START_RETRY_COOLDOWN {- return None;- }+ if let Some(at) = *last_attempt+ && at.elapsed() < COLD_START_RETRY_COOLDOWN+ {+ return None;}*last_attempt = Some(Instant::now());}