diff options
author | Colin Snover <github.com@zetafleet.com> | 2011-02-07 10:52:33 -0600 |
---|---|---|
committer | Colin Snover <github.com@zetafleet.com> | 2011-02-07 10:52:33 -0600 |
commit | 8805f1373d321d7e80e1984bd7e9a3e5d8e50943 (patch) | |
tree | fcb5b08042b4fba8afe170da3b1b16e86a1a29fc | |
parent | 7acb141ed7f2dedd950bb65acf878098640d081e (diff) | |
parent | 5b421fed003e6704bd0fbba2dea5c1b6add2cf52 (diff) | |
download | jquery-8805f1373d321d7e80e1984bd7e9a3e5d8e50943.tar.gz jquery-8805f1373d321d7e80e1984bd7e9a3e5d8e50943.zip |
Merge branch 'master' of github.com:jquery/jquery into jquery-master
-rw-r--r-- | src/ajax.js | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/ajax.js b/src/ajax.js index 2b6b80f90..76f983499 100644 --- a/src/ajax.js +++ b/src/ajax.js @@ -365,9 +365,10 @@ jQuery.extend({ ( s.context = ( "context" in options ? options : jQuery.ajaxSettings ).context ) || s, // Context for global events // It's the callbackContext if one was provided in the options - // and if it's a DOM node - globalEventContext = callbackContext !== s && callbackContext.nodeType ? - jQuery( callbackContext ) : jQuery.event, + // and if it's a DOM node or a jQuery collection + globalEventContext = callbackContext !== s && + ( callbackContext.nodeType || callbackContext instanceof jQuery ) ? + jQuery( callbackContext ) : jQuery.event, // Deferreds deferred = jQuery.Deferred(), completeDeferred = jQuery._Deferred(), |