Replace .map().all(|x| x) by calling .all() in the first place
This commit is contained in:
parent
8e779fc87e
commit
85f79ae3e5
1 changed files with 2 additions and 3 deletions
|
@ -102,11 +102,10 @@ impl StoreId {
|
||||||
self.id
|
self.id
|
||||||
.components()
|
.components()
|
||||||
.zip(colls)
|
.zip(colls)
|
||||||
.map(|(component, pred_coll)| match component {
|
.all(|(component, pred_coll)| match component {
|
||||||
Component::Normal(ref s) => s.to_str().map(|ref s| s == pred_coll).unwrap_or(false),
|
Component::Normal(ref s) => s.to_str().map(|ref s| s == pred_coll).unwrap_or(false),
|
||||||
_ => false
|
_ => false
|
||||||
})
|
}) && colls.last().map(|last| !self.id.ends_with(last)).unwrap_or(false)
|
||||||
.all(|x| x) && colls.last().map(|last| !self.id.ends_with(last)).unwrap_or(false)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue