title: Java Script - replace text with condition
body: <p>There is a list.
  I want change text to "0" if text is "00"
  Doesn't work.</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-js lang-js prettyprint-override"><code>let turnToZero = document.getElementsByClassName("tutorial_length");
  for (var i = 0; i &lt; turnToZero.length; i++){
    let x = turnToZero[i].textContent;
    if ( x = "00" ) { x ="0"} 
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;ul&gt;
     &lt;li class="tutorial_length"&gt;40&lt;/li&gt;
     &lt;li class="tutorial_length"&gt;00&lt;/li&gt;
  &lt;/ul&gt;</code></pre>
  </div>
  </div>
  </p>