mirror of
https://github.com/Hopiu/angular.js.git
synced 2026-05-09 15:24:43 +00:00
fix($compile): compilation should not recurse into empty nodes
if a node doesn't have children then don't try to compile these non-existent children
This commit is contained in:
parent
524c5c8b5d
commit
008a782bc8
1 changed files with 1 additions and 1 deletions
|
|
@ -380,7 +380,7 @@ function $CompileProvider($provide) {
|
||||||
? applyDirectivesToNode(directives, nodeList[i], attrs, transcludeFn, $rootElement)
|
? applyDirectivesToNode(directives, nodeList[i], attrs, transcludeFn, $rootElement)
|
||||||
: null;
|
: null;
|
||||||
|
|
||||||
childLinkFn = (nodeLinkFn && nodeLinkFn.terminal)
|
childLinkFn = (nodeLinkFn && nodeLinkFn.terminal || !nodeList[i].childNodes.length)
|
||||||
? null
|
? null
|
||||||
: compileNodes(nodeList[i].childNodes,
|
: compileNodes(nodeList[i].childNodes,
|
||||||
nodeLinkFn ? nodeLinkFn.transclude : transcludeFn);
|
nodeLinkFn ? nodeLinkFn.transclude : transcludeFn);
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue