aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJohn Resig <jeresig@gmail.com>2010-10-25 13:05:11 -0700
committerJohn Resig <jeresig@gmail.com>2010-10-25 13:05:11 -0700
commitee845c49758eeb5236d9e4520b7921e12d5f29b9 (patch)
tree3e15e88139ec9f45c05b911d8fc267bf94e9c58a /src
parent36143ce63359cc64ebac696f27e4e7968caee902 (diff)
parent3b50eaca2cd0b1439235e39c4e98a6438e8f55b2 (diff)
downloadjquery-ee845c49758eeb5236d9e4520b7921e12d5f29b9.tar.gz
jquery-ee845c49758eeb5236d9e4520b7921e12d5f29b9.zip
Merge branch 'master' of http://github.com/rwldrn/jquery
Diffstat (limited to 'src')
-rw-r--r--src/ajax.js6
-rw-r--r--src/event.js3
2 files changed, 9 insertions, 0 deletions
diff --git a/src/ajax.js b/src/ajax.js
index a40e223e7..915bbaa3e 100644
--- a/src/ajax.js
+++ b/src/ajax.js
@@ -208,6 +208,12 @@ jQuery.extend({
s.data = jQuery.param( s.data, s.traditional );
}
+ // If the jsonpCallback has been set, we can assume that dataType is jsonp
+ // Ticket #5803
+ if ( s.jsonpCallback ) {
+ s.dataType = "jsonp";
+ }
+
// Handle JSONP Parameter Callbacks
if ( s.dataType === "jsonp" ) {
if ( type === "GET" ) {
diff --git a/src/event.js b/src/event.js
index fb5a3ef8c..d491ae8a1 100644
--- a/src/event.js
+++ b/src/event.js
@@ -32,6 +32,9 @@ jQuery.event = {
if ( handler === false ) {
handler = returnFalse;
+ } else if ( !handler ) {
+ // Fixes bug #7229. Fix recommended by jdalton
+ return;
}
var handleObjIn, handleObj;