Second part of the fix for #2071. An empty string "" was being sent to .bind() and when the events were being cleared it went in to an infinite recursive loop till memory was out. The test was !types in the function and changing it to types == undefined fixed the error.

This commit is contained in:
David Serduke 2007-12-19 01:48:05 +00:00
parent 1d7b7b94ef
commit 3bb82a34de

View file

@ -102,7 +102,7 @@ jQuery.event = {
if ( events ) {
// Unbind all events for the element
if ( !types )
if ( types == undefined )
for ( var type in events )
this.remove( elem, type );
else {