Skip to content

Commit

Permalink
clippy lint
Browse files Browse the repository at this point in the history
  • Loading branch information
drHuangMHT committed Feb 5, 2025
1 parent 7817ae0 commit 3d8a93a
Showing 1 changed file with 4 additions and 7 deletions.
11 changes: 4 additions & 7 deletions misc/connection-limits/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -485,13 +485,10 @@ mod tests {
.addresses(vec![addr.clone()])
.build(),
) {
match e {
DialError::Denied { cause } => {
cause
.downcast::<Exceeded>()
.expect_err("Unexpected connection denied because of limit");
}
_ => {}
if let DialError::Denied { cause } = e {

Check failure on line 488 in misc/connection-limits/src/lib.rs

View workflow job for this annotation

GitHub Actions / clippy (1.83.0)

this `if let` can be collapsed into the outer `if let`

Check failure on line 488 in misc/connection-limits/src/lib.rs

View workflow job for this annotation

GitHub Actions / clippy (beta)

this `if let` can be collapsed into the outer `if let`
cause
.downcast::<Exceeded>()
.expect_err("Unexpected connection denied because of limit");
}
}
let not_bypassed_peer = loop {
Expand Down

0 comments on commit 3d8a93a

Please sign in to comment.