Fixed NoneType bug with search results