Skip to content
Permalink
Browse files

Handle issue with two concurrent JSONP requests that use the same cal…

…lback name.
  • Loading branch information...
Pinhook authored and jeresig committed Oct 13, 2010
1 parent 8fb4d9a commit 39addc87a37b32be19f2c58ec8babe752c0243e1
Showing with 4 additions and 4 deletions.
  1. +4 −4 src/ajax.js
@@ -239,10 +239,6 @@ jQuery.extend({
var customJsonp = window[ jsonp ];

window[ jsonp ] = function( tmp ) {
data = tmp;
jQuery.handleSuccess( s, xhr, status, data );
jQuery.handleComplete( s, xhr, status, data );

if ( jQuery.isFunction( customJsonp ) ) {
customJsonp( tmp );

@@ -258,6 +254,10 @@ jQuery.extend({
if ( head ) {
head.removeChild( script );
}

data = tmp;
jQuery.ajax.handleSuccess( s, xhr, status, data );
jQuery.ajax.handleComplete( s, xhr, status, data );
};
}

2 comments on commit 39addc8

@kswedberg

This comment has been minimized.

Copy link
Member

replied Oct 14, 2010

This commit is killing the test suite at test 242. I'm pretty sure jQuery.ajax.handleSuccess and jQuery.ajax.handleComplete should still be jQuery.handleSuccess and jQuery.handleComplete for the time being.

@jeresig

This comment has been minimized.

Copy link
Member

replied Oct 14, 2010

Good catch Karl - fixed: d490bcf

Please sign in to comment.
You can’t perform that action at this time.