aboutsummaryrefslogtreecommitdiffstats
path: root/src/Compiler.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/Compiler.js')
-rw-r--r--src/Compiler.js4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/Compiler.js b/src/Compiler.js
index a6fd88ec..bcf1f61a 100644
--- a/src/Compiler.js
+++ b/src/Compiler.js
@@ -30,7 +30,9 @@ Template.prototype = {
element = jqLite(element);
foreach(this.inits, function(fn) {
queue.push(function(scope) {
- scope.$tryEval(fn, element, element);
+ scope.$tryEval(function(){
+ return fn.call(scope, element);
+ }, element);
});
});