Regression in replace(Element, Element) method on Cache