fixed a case where searching right would search into next row