Hacker News new | past | comments | ask | show | jobs | submit login

The filter_map explanation is wrong. .ok() converts a result to an Option, not a boolean. Likewise, filter_map expects an option. That's how it can both filter and map.

Docs: https://doc.rust-lang.org/std/result/enum.Result.html#method...

Thanks for the hint. Will fix that and give you some credits.

Edit fixed.

Guidelines | FAQ | Support | API | Security | Lists | Bookmarklet | Legal | Apply to YC | Contact