Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Added a check to make sure a parent node exists in call remove() to a…
…void errors as seen in bug #1742.
  • Loading branch information
davids549 committed Nov 5, 2007
1 parent 98204c7 commit a613a70
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/core.js
Expand Up @@ -1268,7 +1268,8 @@ jQuery.each({
jQuery.event.remove(this);
jQuery.removeData(this);
});
this.parentNode.removeChild( this );
if (this.parentNode)
this.parentNode.removeChild( this );
}
},

Expand Down

0 comments on commit a613a70

Please sign in to comment.