humflelump / async-selector-kit

An opinionated API to simplify using async-selector
6 stars 2 forks source link

Correct getting started example #32

Open dpwrussell opened 3 years ago

dpwrussell commented 3 years ago

I gave the getting started example a try and spent a few minutes debugging a non-existent problem with my application.

The actual issue is that the example seems to have the search filtering backwards. I.e. it looks for the items from the database in the search term instead of the other way around. So 'Mark' from ['Mark Metzger', 'Steve Miller'] would return [] instead of ['Mark Metzger'].

This PR corrects that to look for the search term in in each item in the "database".