diff options
author | Devin Wilson <dwilson6.github@gmail.com> | 2016-01-13 21:06:43 -0700 |
---|---|---|
committer | Timmy Willison <timmywillisn@gmail.com> | 2016-01-19 12:27:58 -0500 |
commit | 17f0e26ad9eba67ab274d12274cf7c23c8c688fd (patch) | |
tree | f10ba07dff38ebc535e8d0c299662cdd0984e91e /src | |
parent | 780cac802b32a0125c467a644b3803be378ae6ab (diff) | |
download | jquery-17f0e26ad9eba67ab274d12274cf7c23c8c688fd.tar.gz jquery-17f0e26ad9eba67ab274d12274cf7c23c8c688fd.zip |
Event: Fix chaining .on() with null handlers
Fixes gh-2846
Diffstat (limited to 'src')
-rw-r--r-- | src/event.js | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/event.js b/src/event.js index ddd92c5fc..c8a14fe7d 100644 --- a/src/event.js +++ b/src/event.js @@ -70,6 +70,8 @@ function on( elem, types, selector, data, fn, one ) { } if ( fn === false ) { fn = returnFalse; + } else if ( !fn ) { + return elem; } if ( one === 1 ) { |