Replace "map(..).unwrap_or(false)" with "is_some_and(..)" everywhere (#40244)

Testing: This change is a simple cleanup and should mostly be covered by
existing tests.

Signed-off-by: Simon Wülker <simon.wuelker@arcor.de>
This commit is contained in:
Simon Wülker
2025-10-28 22:19:04 +01:00
committed by GitHub
parent aac7d9006e
commit c14795b33a
9 changed files with 18 additions and 31 deletions

View File

@@ -633,7 +633,7 @@ impl TestBindingMethods<crate::DomTypeHolder> for TestBinding {
}
fn DictMatchesPassedValues(&self, arg: RootedTraceableBox<TestDictionary>) -> bool {
arg.type_.as_ref().map(|s| s == "success").unwrap_or(false) &&
arg.type_.as_ref().is_some_and(|s| s == "success") &&
arg.nonRequiredNullable.is_none() &&
arg.nonRequiredNullable2 == Some(None) &&
arg.noCallbackImport.is_none() &&