Skip to content

Commit 0fa414d

Browse files
committed
clippy complaints
1 parent 6880ebf commit 0fa414d

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

src/policy/denylist.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ impl Denylist {
8282

8383
// If there's no country code info -> then we don't block by default
8484
// TODO discuss
85-
country_code.map_or(false, |code| entry.iter().any(|x| *x == code.0))
85+
country_code.is_some_and(|code| entry.iter().any(|x| *x == code.0))
8686
}
8787

8888
pub async fn update(&self) -> Result<usize, Error> {

src/policy/domain_canister.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,7 @@ pub const SYSTEM_SUBNETS: [(Principal, Principal); 5] = [
2929
pub fn is_system_subnet(canister_id: Principal) -> bool {
3030
SYSTEM_SUBNETS
3131
.iter()
32-
.map(|x| canister_id >= x.0 && canister_id <= x.1)
33-
.any(|x| x)
32+
.any(|x| canister_id >= x.0 && canister_id <= x.1)
3433
}
3534

3635
// Things needed to verify domain-canister match

src/tls/cert/providers/dir.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ impl ProvidesCertificates for Provider {
3838
if !v
3939
.path()
4040
.extension()
41-
.map_or(false, |x| x.eq_ignore_ascii_case("pem"))
41+
.is_some_and(|x| x.eq_ignore_ascii_case("pem"))
4242
{
4343
continue;
4444
}

0 commit comments

Comments
 (0)