chore: update dependencies

This commit is contained in:
Michael Aaron Murphy 2024-08-21 03:07:16 +02:00
parent 6948373a68
commit 3ec53d7f8a
No known key found for this signature in database
GPG key ID: B2732D4240C9212C
10 changed files with 350 additions and 304 deletions

View file

@ -204,16 +204,11 @@ impl<Message: 'static> Binder<Message> {
&'a self,
rule: &'a Regex,
) -> impl Iterator<Item = (crate::Entity, section::Entity)> + 'a {
generator::Gn::new_scoped_local(|mut s| {
for (page, sections) in self.content.iter() {
for id in sections {
if self.sections[*id].search_matches(rule) {
s.yield_((page, *id));
}
}
}
generator::done!();
self.content.iter().flat_map(move |(page, sections)| {
sections
.into_iter()
.filter(|&id| self.sections[*id].search_matches(rule))
.map(move |&id| (page, id))
})
}