Modified to properly find indexed xpath.