diff options
| author | Misko Hevery | 2010-07-20 16:55:32 -0700 |
|---|---|---|
| committer | Misko Hevery | 2010-07-20 16:55:32 -0700 |
| commit | bebfbeac0a3f25b3d0df00ada5c919adef9dd701 (patch) | |
| tree | 9d985f8c357dbcbc6f24a8c348c1336d2c32d99c /src/Compiler.js | |
| parent | 7e96af0fdd9af8c479992363f68578305df0337e (diff) | |
| download | angular.js-bebfbeac0a3f25b3d0df00ada5c919adef9dd701.tar.bz2 | |
fixed xhtml compatibility, fix console in chrome
Diffstat (limited to 'src/Compiler.js')
| -rw-r--r-- | src/Compiler.js | 11 |
1 files changed, 8 insertions, 3 deletions
diff --git a/src/Compiler.js b/src/Compiler.js index 9faafb13..a6fd88ec 100644 --- a/src/Compiler.js +++ b/src/Compiler.js @@ -121,20 +121,25 @@ Compiler.prototype = { descend: function(value){ if(isDefined(value)) descend = value; return descend;}, directives: function(value){ if(isDefined(value)) directives = value; return directives;} }; - priority = element.attr('ng:eval-order') || priority || 0; + try { + priority = element.attr('ng:eval-order') || priority || 0; + } catch (e) { + // for some reason IE throws error under some weird circumstances. so just assume nothing + priority = priority || 0; + } if (isString(priority)) { priority = PRIORITY[uppercase(priority)] || 0; } template = new Template(priority); eachAttribute(element, function(value, name){ if (!widget) { - if (widget = self.widgets['@' + name]) { + if (widget = self.widgets('@' + name)) { widget = bind(selfApi, widget, value, element); } } }); if (!widget) { - if (widget = self.widgets[nodeName(element)]) { + if (widget = self.widgets(nodeName(element))) { widget = bind(selfApi, widget, element); } } |
