summaryrefslogtreecommitdiffstats
path: root/lib/handlebars/compiler/helpers.js
diff options
context:
space:
mode:
authorkpdecker <kpdecker@gmail.com>2014-11-07 21:23:51 -0600
committerkpdecker <kpdecker@gmail.com>2014-11-08 14:35:23 -0600
commitd47e4dd1f742ae90d71b4fd5141a0e7577098cc5 (patch)
tree53067edaf558fe7bc02fbe804f50953ee99befae /lib/handlebars/compiler/helpers.js
parent83bcbee222077350ee2b7e3322f0cdad18f34b83 (diff)
downloadhandlebars.js-d47e4dd1f742ae90d71b4fd5141a0e7577098cc5.zip
handlebars.js-d47e4dd1f742ae90d71b4fd5141a0e7577098cc5.tar.gz
handlebars.js-d47e4dd1f742ae90d71b4fd5141a0e7577098cc5.tar.bz2
Bump test coverage
Diffstat (limited to 'lib/handlebars/compiler/helpers.js')
-rw-r--r--lib/handlebars/compiler/helpers.js3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/handlebars/compiler/helpers.js b/lib/handlebars/compiler/helpers.js
index 20f13d6..5aa0f2c 100644
--- a/lib/handlebars/compiler/helpers.js
+++ b/lib/handlebars/compiler/helpers.js
@@ -98,7 +98,8 @@ export function prepareProgram(statements, isRoot) {
if (omitLeft(statements, i)) {
// If we are on a standalone node, save the indent info for partials
if (current.type === 'partial') {
- current.indent = (/([ \t]+$)/).exec(statements[i-1].original) ? RegExp.$1 : '';
+ // Pull out the whitespace from the final line
+ current.indent = (/([ \t]+$)/).exec(statements[i-1].original)[1];
}
}
}