Fixed search bug and deleteTab bug