Refactored DOMNodeList array dereferencing implementation