Cache some methods outside of iterations
Handle bug which was generating some erroneous head relationships in the DOM info