Skip to content
This repository has been archived by the owner on Mar 13, 2018. It is now read-only.

Commit

Permalink
Wrap the document, and handle null
Browse files Browse the repository at this point in the history
  • Loading branch information
jakemac53 committed Oct 1, 2014
1 parent 1f5e073 commit a007bcd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Observer.js
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ function handler(mutations) {

function takeRecords(node) {
// If the optional node is not supplied, assume we mean the whole document.
if (node === undefined) node = document;
if (!node) node = wrapIfNeeded(document);

// Find the root of the tree, which will be an Document or ShadowRoot.
while (node.parentNode) {
Expand Down

0 comments on commit a007bcd

Please sign in to comment.