From 612a908514b6ad6ec35754b0193887b01ce2c9f2 Mon Sep 17 00:00:00 2001 From: rwldrn Date: Sat, 1 Jan 2011 13:49:59 -0500 Subject: #7883 .delegate and .live should accept false as the fn arg, like bind --- src/event.js | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src') diff --git a/src/event.js b/src/event.js index 675e5fff3..4d908b92d 100644 --- a/src/event.js +++ b/src/event.js @@ -1023,10 +1023,15 @@ jQuery.each(["live", "die"], function( i, name ) { return this; } - if ( jQuery.isFunction( data ) ) { + if ( jQuery.isFunction( data ) || data === false ) { fn = data; data = undefined; } + + if ( fn === false ) { + fn = returnFalse; + } + types = (types || "").split(" "); -- cgit v1.2.3