Changing xpElemList to correctly return an empty list if the element doesn't exist