X-Git-Url: http://git.asbjorn.biz/?a=blobdiff_plain;f=src%2Fajax.js;h=a40e223e76dd599790c08e18c086a11feb268922;hb=424500bcf068a234b13cd9ef33d94580c35eeb86;hp=d06bbabd94aa8e41b9b6da8b9a406c2dc68f226a;hpb=6245ecb2b91cca73f66dc0543beb6626c138bcfc;p=jquery.git diff --git a/src/ajax.js b/src/ajax.js index d06bbab..a40e223 100644 --- a/src/ajax.js +++ b/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 ); @@ -254,6 +250,10 @@ jQuery.extend({ delete window[ jsonp ]; } catch( jsonpError ) {} } + + data = tmp; + jQuery.handleSuccess( s, xhr, status, data ); + jQuery.handleComplete( s, xhr, status, data ); if ( head ) { head.removeChild( script );