X-Git-Url: http://git.asbjorn.biz/?a=blobdiff_plain;f=src%2Fajax.js;h=a40e223e76dd599790c08e18c086a11feb268922;hb=d9a3e0080a4ffe472a2ee4458b223fb1feb8021c;hp=1602ed25a5ef6a20444e23a62e513f319da55405;hpb=80a4178af9b12e6617bfcec818c538dfe08d3791;p=jquery.git diff --git a/src/ajax.js b/src/ajax.js index 1602ed2..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 );