title: FreeMarker Error : left-hand operand: Expected a hash, but this evaluated to a sequence
body: <p>When I loop through a list in freemarker like below, it works fine.</p>
  
  <pre><code>&lt;#list cModel.products as product&gt;
  </code></pre>
  
  <p>But when I'm tring to assign the size of the list to a variable like,</p>
  
  <pre><code> &lt;#assign totalProducts = cModel.products.getList()?size&gt;
  </code></pre>
  
  <p>I'm getting an exception from free marker like below</p>
  
  <blockquote>
    <p>left-hand operand: Expected a hash, but this evaluated to a sequence</p>
  </blockquote>
  
  <p>Any suggestions?</p>