working on the search functionality