chore(dict): Don't clear disallowed words

This commit is contained in:
Ed Page 2023-08-07 16:23:36 -05:00
parent 41ce6be897
commit a3bf84ade6

View file

@ -81,13 +81,9 @@ fn process<S: Into<String>>(
let rows: Dict = dict let rows: Dict = dict
.into_iter() .into_iter()
.filter(|(t, _)| is_word(t)) .filter(|(t, _)| is_word(t))
.filter_map(|(t, c)| { .map(|(t, c)| {
let new_c: IndexSet<_> = c.into_iter().filter(|c| is_word(c)).collect(); let new_c: IndexSet<_> = c.into_iter().filter(|c| is_word(c)).collect();
if new_c.is_empty() { (t, new_c)
None
} else {
Some((t, new_c))
}
}) })
.collect(); .collect();