Skip to content

Commit

Permalink
fix(view-strategy): handle detached
Browse files Browse the repository at this point in the history
  • Loading branch information
martingust committed Mar 25, 2016
1 parent 029e6ef commit 4f10fcc
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/view-strategy.js
Expand Up @@ -40,9 +40,9 @@ export class TableStrategy {
return buffer;
}

removeBufferElements(scrollList, topBuffer, bottomBuffer) {
scrollList.removeChild(topBuffer.parentElement);
scrollList.removeChild(bottomBuffer.parentElement);
removeBufferElements(element, topBuffer, bottomBuffer) {
element.parentElement.removeChild(topBuffer.parentElement);
element.parentElement.removeChild(bottomBuffer.parentElement);
}
}

Expand Down Expand Up @@ -76,7 +76,7 @@ export class DefaultStrategy {
}

removeBufferElements(element, topBuffer, bottomBuffer) {
element.removeChild(topBuffer);
element.removeChild(bottomBuffer);
element.parentElement.removeChild(topBuffer);
element.parentElement.removeChild(bottomBuffer);
}
}

0 comments on commit 4f10fcc

Please sign in to comment.