Fix SearchRebuild bug