Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: fixed a bug in new_strings (#45)
The bug was caused by reassigning new_strings inside a try_for_each block. new_strings = results_vec .into_iter() .flat_map(|r| r.unencrypted_text) .filter(|s| seen_strings.insert(s.clone())) .collect(); This was overwriting the content of new_strings with the strings from result_vec of the last result it got from running decoders. This isn't intended. we want strings from all results. Therefore, we use .extend to extend our new_strings with the strings from each result_vec new_strings.extend( results_vec .into_iter() .flat_map(|r| r.unencrypted_text) .filter(|s| seen_strings.insert(s.clone())), ); Link to Discussion
- Loading branch information