Enable clippy::search_is_some (#8748)
This PR enables the [`clippy::search_is_some`](https://rust-lang.github.io/rust-clippy/master/index.html#/search_is_some) rule and fixes the outstanding violations. Release Notes: - N/A
This commit is contained in:
@@ -8,7 +8,7 @@ struct FeatureFlags {
|
||||
|
||||
impl FeatureFlags {
|
||||
fn has_flag(&self, flag: &str) -> bool {
|
||||
self.staff || self.flags.iter().find(|f| f.as_str() == flag).is_some()
|
||||
self.staff || self.flags.iter().any(|f| f.as_str() == flag)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user