diff options
Diffstat (limited to 'lib/template.js')
-rw-r--r-- | lib/template.js | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/template.js b/lib/template.js index 08e1877..0565824 100644 --- a/lib/template.js +++ b/lib/template.js @@ -93,7 +93,7 @@ TemplateEngine.prototype.processBlock = function(blk) { }); blk.id = _.uniqueId("blk"); - var toAdd = blk.parse || (blk.post != undefined); + var toAdd = (!blk.parse) || (blk.post != undefined); // Add to global map if (toAdd) this.blocks[blk.id] = blk; @@ -368,7 +368,7 @@ TemplateEngine.prototype.postProcess = function(content) { return Q(content) .then(that.replaceBlocks) - .then(function(content) { + .then(function(_content) { return batch.execEach(that.blocks, { max: 20, fn: function(blk, blkId) { @@ -382,7 +382,7 @@ TemplateEngine.prototype.postProcess = function(content) { }); } }) - .thenResolve(content); + .thenResolve(_content); }); }; |