summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/handlebars/base.js2
-rw-r--r--lib/handlebars/compiler/ast.js2
-rw-r--r--lib/handlebars/compiler/compiler.js2
-rw-r--r--lib/handlebars/compiler/javascript-compiler.js2
-rw-r--r--lib/handlebars/runtime.js4
5 files changed, 4 insertions, 8 deletions
diff --git a/lib/handlebars/base.js b/lib/handlebars/base.js
index 2dfca02..0bc2948 100644
--- a/lib/handlebars/base.js
+++ b/lib/handlebars/base.js
@@ -194,7 +194,7 @@ function registerDefaultHelpers(instance) {
instance.log(level, context);
});
- instance.registerHelper('lookup', function(obj, field, options) {
+ instance.registerHelper('lookup', function(obj, field) {
return obj && obj[field];
});
}
diff --git a/lib/handlebars/compiler/ast.js b/lib/handlebars/compiler/ast.js
index 66533a5..49bdc33 100644
--- a/lib/handlebars/compiler/ast.js
+++ b/lib/handlebars/compiler/ast.js
@@ -37,8 +37,6 @@ var AST = {
this.sexpr = new AST.SexprNode(rawParams, hash);
}
- this.sexpr.isRoot = true;
-
// Support old AST API that stored this info in MustacheNode
this.id = this.sexpr.id;
this.params = this.sexpr.params;
diff --git a/lib/handlebars/compiler/compiler.js b/lib/handlebars/compiler/compiler.js
index eafee74..1aba34b 100644
--- a/lib/handlebars/compiler/compiler.js
+++ b/lib/handlebars/compiler/compiler.js
@@ -244,7 +244,7 @@ Compiler.prototype = {
id.falsy = true;
this.ID(id);
- this.opcode('invokeHelper', params.length, id.original, id.isSimple, sexpr.isRoot);
+ this.opcode('invokeHelper', params.length, id.original, id.isSimple);
}
},
diff --git a/lib/handlebars/compiler/javascript-compiler.js b/lib/handlebars/compiler/javascript-compiler.js
index c59fd70..19066d3 100644
--- a/lib/handlebars/compiler/javascript-compiler.js
+++ b/lib/handlebars/compiler/javascript-compiler.js
@@ -515,7 +515,7 @@ JavaScriptCompiler.prototype = {
// and pushes the helper's return value onto the stack.
//
// If the helper is not found, `helperMissing` is called.
- invokeHelper: function(paramSize, name, isSimple, isRoot) {
+ invokeHelper: function(paramSize, name, isSimple) {
this.aliases.helperMissing = 'helpers.helperMissing';
var nonHelper = this.popStack();
diff --git a/lib/handlebars/runtime.js b/lib/handlebars/runtime.js
index ca85d84..5970175 100644
--- a/lib/handlebars/runtime.js
+++ b/lib/handlebars/runtime.js
@@ -120,9 +120,7 @@ export function template(templateSpec, env) {
var ret = function(context, options) {
options = options || {};
- var helpers,
- partials,
- data = options.data;
+ var data = options.data;
ret._setup(options);
if (!options.partial && templateSpec.useData) {