diff options
| author | Misko Hevery | 2013-06-11 13:08:21 -0700 |
|---|---|---|
| committer | Misko Hevery | 2013-06-11 13:14:34 -0700 |
| commit | b28f96949ac477b1fe43c81df7cedc21c7ab184c (patch) | |
| tree | d4fe798bbe154941a0caeb4592c3d614d057d9f1 /src/ng/compile.js | |
| parent | 6b12432729848d3b34689f62a6bcd1766fd29720 (diff) | |
| download | angular.js-b28f96949ac477b1fe43c81df7cedc21c7ab184c.tar.bz2 | |
fix($compile): support multi-element group over text nodes
Diffstat (limited to 'src/ng/compile.js')
| -rw-r--r-- | src/ng/compile.js | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/ng/compile.js b/src/ng/compile.js index d231fb40..ba6e6306 100644 --- a/src/ng/compile.js +++ b/src/ng/compile.js @@ -591,8 +591,10 @@ function $CompileProvider($provide) { if (!node) { throw ngError(51, "Unterminated attribute, found '{0}' but no matching '{1}' found.", attrStart, attrEnd); } - if (node.hasAttribute(attrStart)) depth++; - if (node.hasAttribute(attrEnd)) depth--; + if (node.nodeType == 1 /** Element **/) { + if (node.hasAttribute(attrStart)) depth++; + if (node.hasAttribute(attrEnd)) depth--; + } nodes.push(node); node = node.nextSibling; } while (depth > 0); |
