title: Cannot read properties of undefined (reading 'childNodes')
body: <p>I am trying to parse a text to a text/xml and get the value that is inside a child Node but is giving this error to me (Cannot read properties of undefined (reading 'childNodes').
  I want the value true inside of the GetValidUserPasswordResult.
  This is the code that i am making:</p>
  <pre><code>    var text = '&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;&lt;soap:Envelope xmlns:soap=&quot;http://www.w3.org/2003/05/soap-envelope&quot; xmlns:xsi=&quot;http://www.w3.org/2001/XMLSchema-instance&quot; xmlns:xsd=&quot;http://www.w3.org/2001/XMLSchema&quot;&gt;&lt;soap:Body&gt;&lt;GetValidUserPasswordResponse xmlns=&quot;http://microsoft.com/webservices/&quot;&gt;&lt;GetValidUserPasswordResult&gt;true&lt;/GetValidUserPasswordResult&gt;&lt;/GetValidUserPasswordResponse&gt;&lt;/soap:Body&gt;&lt;/soap:Envelope&gt;';
      console.log(text);
      parser = new DomParser();
      xmlDoc = parser.parseFromString(text, &quot;text/xml&quot;);
  
  
  xmlDoc1 = xmlDoc.getElementsByName(&quot;GetValidUserPasswordResult&quot;)[0].childNodes[0].text;
  console.log(xmlDoc1)
  </code></pre>