Debug the search, make it faster