Refs #17217.  Check for type Array so that NodeList works.  Added automated test.