Validate the property $childNodes, replacing call to hasChildNodes()