fixed search (it was reverse sorting results)