fix empty search bug