saving the search cleanup