Skip to content

Commit

Permalink
run clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
muhamadazmy committed Apr 5, 2024
1 parent deccc8e commit 24498b7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/relay/api.rs
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ async fn federation<D: TwinDB, R: RateLimiter>(
}

async fn update_cache_relays(envelope: &Envelope, twin_db: &impl TwinDB) -> Result<()> {
if envelope.relays.len() == 0 {
if envelope.relays.is_empty() {
return Ok(());
}
let mut twin = twin_db
Expand Down Expand Up @@ -333,7 +333,7 @@ impl<M: Metrics, D: TwinDB> Stream<M, D> {
.await?
.ok_or_else(|| anyhow::Error::msg("unknown twin destination"))?;

update_cache_relays(&envelope, &self.twins).await?;
update_cache_relays(envelope, &self.twins).await?;

if !twin
.relay
Expand Down

0 comments on commit 24498b7

Please sign in to comment.