title: scrollHeight is more than clientHeight, even without scrolling content
body: <p>I have a piece of JS code that determines whether there is a vertical scrollbar and applies a CSS class to an element. Nothing big.
  What is confusing me is it appears to be doing the opposite of what I understand it should be doing. This isn't a problem unless it is a bug and is fixed in the future.<br>
  The code:  </p>
  
  <pre><code>if (document.body.scrollHeight &gt; document.body.clientHeight) {
      var d = document.getElementById("footer").className = "footernoscroll";
  }
  </code></pre>
  
  <p>My understanding is that it will apply the class if there is a vertical scroll bar, but it appears to be applying the class if there <strong>isn't</strong> a scroll bar. Am I interpreting this correctly and the code is acting strangely or is my interpretation wrong?</p>
  
  <p><strong>EDIT:</strong> Thought I should add, if I reverse the operator the effects will be reversed and it will use the <code>else</code> part of the statement instead.</p>