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

Commit

Permalink
only check for is object on instance (not prototype)
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaelw committed Mar 17, 2014
1 parent d7050c2 commit 5db3ef5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/observe.js
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,7 @@
for (var i = 0; i < this.length; i++) {
if (i)
obj = obj[this[i - 1]];
if (!obj)
if (!isObject(obj))
return;
observe(obj);
}
Expand Down Expand Up @@ -420,7 +420,7 @@
var resetScheduled = false;

function observe(obj) {
if (!isObject(obj))
if (!obj)
return;

var index = toRemove.indexOf(obj);
Expand Down

0 comments on commit 5db3ef5

Please sign in to comment.