Skip to content

Commit

Permalink
Correct NodeList copying.
Browse files Browse the repository at this point in the history
  • Loading branch information
Steven Orvell committed Oct 19, 2015
1 parent 9c5a404 commit 1d29e19
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/lib/dom-api.html
Original file line number Diff line number Diff line change
Expand Up @@ -927,8 +927,10 @@
// is populated.
if (!node._lightChildren) {
var c$ = [];
for (var a=node.firstChild; a = a && a.nextSibling;) {
c$.push(a);
var n = node.firstChild;
while (n) {
c$.push(n);
n = n.nextSibling;
}
for (var i=0, l=c$.length, child; (i<l) && (child=c$[i]); i++) {
child._lightParent = child._lightParent || node;
Expand Down

0 comments on commit 1d29e19

Please sign in to comment.