compare search bug fix