Added some functionality to search bar