update search in rotated array