complete the search users function