fixed search bug from last commit