wycats/handlebars.js — pull request #731 by kpdecker (2014-07-07 04:42:26+00:00)
Title: Strange behavior for {{#foo}} {{bar}} {{/foo}} when foo is 0

var tmpl = Handlebars.compile('{{#foo}} This is {{bar}} ~ {{/foo}}');
alert(tmpl({ foo: 0, bar: 'OK' }));

in handebars.js 1.0.21 (or older version) we get output: ' This is ~ '
in handlebars.js 1.1.0 (or newer version) we get output ' This is 0 ~ '

Is this a designed behavior or bug?

* When {{#foo}} section and foo === 0 , all {{any_name}} inside the section will be rendering as 0.