prevents adding an emtpy search query to the search query history list