mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-09-01 21:49:21 +03:00
Resolve #1797
This commit is contained in:
parent
ececfae31a
commit
cb9e1b0705
5 changed files with 13 additions and 9 deletions
|
|
@ -38,10 +38,12 @@ ko.bindingProvider = new class
|
|||
// Deprecated: with is no longer recommended
|
||||
var rewrittenBindings = ko.expressionRewriting.preProcessBindings(bindingsString),
|
||||
functionBody = "with($data){return{" + rewrittenBindings + "}}";
|
||||
bindingFunction = new Function("$root", "$parent", "$data", "$element", functionBody);
|
||||
bindingFunction = new Function("$context", "$root", "$parent", "$data", "$element", functionBody);
|
||||
bindingCache.set(cacheKey, bindingFunction);
|
||||
}
|
||||
return bindingFunction(bindingContext["$root"], bindingContext["$parent"], bindingContext["$data"] || {}, node);
|
||||
return bindingFunction(bindingContext,
|
||||
bindingContext["$root"], bindingContext["$parent"], bindingContext["$data"] || {}, node
|
||||
);
|
||||
} catch (ex) {
|
||||
ex.message = "Unable to parse bindings.\nBindings value: " + bindingsString
|
||||
+ "\nMessage: " + ex.message;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue