aboutsummaryrefslogtreecommitdiffstats
path: root/src/directives.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/directives.js')
-rw-r--r--src/directives.js20
1 files changed, 11 insertions, 9 deletions
diff --git a/src/directives.js b/src/directives.js
index 06a99149..53601a4f 100644
--- a/src/directives.js
+++ b/src/directives.js
@@ -243,15 +243,17 @@ function compileBindTemplate(template){
var bindings = [];
forEach(parseBindings(template), function(text){
var exp = binding(text);
- bindings.push(exp ? function(element){
- var error, value = this.$tryEval(exp, function(e){
- error = toJson(e);
- });
- elementError(element, NG_EXCEPTION, error);
- return error ? error : value;
- } : function() {
- return text;
- });
+ bindings.push(exp
+ ? function(element){
+ var error, value = this.$tryEval(exp, function(e){
+ error = toJson(e);
+ });
+ elementError(element, NG_EXCEPTION, error);
+ return error ? error : value;
+ }
+ : function() {
+ return text;
+ });
});
bindTemplateCache[template] = fn = function(element, prettyPrintJson){
var parts = [], self = this,