Shorten up the code and do event cleanup on test cases.
This commit is contained in:
parent
b5c7c507c1
commit
c1316a4cb1
2 changed files with 5 additions and 8 deletions
11
src/event.js
11
src/event.js
|
@ -1027,15 +1027,10 @@ jQuery.each(["live", "die"], function( i, name ) {
|
|||
return this;
|
||||
}
|
||||
|
||||
if ( jQuery.isFunction( data ) || data === false ) {
|
||||
fn = data;
|
||||
if ( data === false || jQuery.isFunction( data ) ) {
|
||||
fn = data || returnFalse;
|
||||
data = undefined;
|
||||
}
|
||||
|
||||
if ( fn === false ) {
|
||||
fn = returnFalse;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
types = (types || "").split(" ");
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue