can't go through simple JavaScript prototype's method
<p>I have written some JavaScript code. It adds new function to NodeList type in this way:</p>

<pre><code>NodeList.prototype.forEach = function(func) {
var len = this.length
for(var i=0;i&lt;len;i++) func(this[i])
}
</code></pre>

<p>It is used somewhere else like that:</p>

<pre><code>document.getElementsByTagName("fieldset").forEach(disappearFields)
</code></pre>

<p>All is really simple.</p>

<p>It works nice in chrome but firefox gives an error:</p>

<blockquote>
  <p>document.getElementsByTagName("fieldset").forEach is not a function
  [Break on this error] document.getElementsByTagName("fieldset").forEach(disappearFields) </p>
</blockquote>

<p>disappearFields is short function:</p>

<pre><code>function disappearFields(what) {
what.style.display = "none"
}
</code></pre>

<p>I have looked for any help in google but according to those information my code should work properly. I am not able to cope with that myself. Any help 'll be appreciated.</p>
