Commit ea5d5140 authored by jeresig's avatar jeresig

When .bind('unload') was called it accidentally went recursive, from...

When .bind('unload') was called it accidentally went recursive, from 1bac6165. Fixes #5688.
parent a00e63ea
......@@ -778,9 +778,11 @@ jQuery.each(["bind", "one"], function( i, name ) {
jQuery( this ).unbind( event, handler );
return fn.apply( this, arguments );
}) : fn;
return type === "unload" ? this.one(type, data, handler, thisObject) : this.each(function() {
jQuery.event.add( this, type, handler, data );
});
return type === "unload" && name !== "one" ?
this.one( type, data, fn, thisObject ) :
this.each(function() {
jQuery.event.add( this, type, handler, data );
});
};
});
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment