diff options
author | Nicolas Chambrier <naholyr@gmail.com> | 2012-06-25 17:38:27 +0300 |
---|---|---|
committer | Nicolas Chambrier <naholyr@gmail.com> | 2012-06-25 17:38:27 +0300 |
commit | 7a393a972ba20d88af0805f92c99fbdfd9db89ed (patch) | |
tree | 52b4dc55fefd9d2ef84dec09ee2e87aff192ad91 /lib/handlebars/compiler/compiler.js | |
parent | 0afc8b58d218d6220d5efdd2509754d13d9e1c55 (diff) | |
download | handlebars.js-7a393a972ba20d88af0805f92c99fbdfd9db89ed.zip handlebars.js-7a393a972ba20d88af0805f92c99fbdfd9db89ed.tar.gz handlebars.js-7a393a972ba20d88af0805f92c99fbdfd9db89ed.tar.bz2 |
FIX global leak
Diffstat (limited to 'lib/handlebars/compiler/compiler.js')
-rw-r--r-- | lib/handlebars/compiler/compiler.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/handlebars/compiler/compiler.js b/lib/handlebars/compiler/compiler.js index 20a558d..6807494 100644 --- a/lib/handlebars/compiler/compiler.js +++ b/lib/handlebars/compiler/compiler.js @@ -96,7 +96,7 @@ Handlebars.JavaScriptCompiler = function() {}; this.children[guid] = result; for(var i=0, l=result.depths.list.length; i<l; i++) { - depth = result.depths.list[i]; + var depth = result.depths.list[i]; if(depth < 2) { continue; } else { this.addDepth(depth - 1); } @@ -831,7 +831,7 @@ Handlebars.JavaScriptCompiler = function() {}; var programParams = [child.index, child.name, "data"]; for(var i=0, l = depths.length; i<l; i++) { - depth = depths[i]; + var depth = depths[i]; if(depth === 1) { programParams.push("depth0"); } else { programParams.push("depth" + (depth - 1)); } |