mirror of
https://github.com/jquery/jquery.git
synced 2026-04-20 03:01:22 -04:00
Tweak spacing from last commit.
This commit is contained in:
26
src/ajax.js
26
src/ajax.js
@@ -238,23 +238,24 @@ jQuery.extend({
|
||||
|
||||
// Handle JSONP-style loading
|
||||
var customJsonp = window[ jsonp ];
|
||||
|
||||
window[ jsonp ] = function( tmp ) {
|
||||
data = tmp;
|
||||
jQuery.ajax.handleSuccess( s, xhr, status, data );
|
||||
jQuery.ajax.handleComplete( s, xhr, status, data );
|
||||
|
||||
if ( jQuery.isFunction( customJsonp ) ) {
|
||||
customJsonp( tmp );
|
||||
}
|
||||
else {
|
||||
// Garbage collect
|
||||
window[ jsonp ] = undefined;
|
||||
customJsonp( tmp );
|
||||
|
||||
try {
|
||||
delete window[ jsonp ];
|
||||
} catch( jsonpError ) {}
|
||||
}
|
||||
|
||||
} else {
|
||||
// Garbage collect
|
||||
window[ jsonp ] = undefined;
|
||||
|
||||
try {
|
||||
delete window[ jsonp ];
|
||||
} catch( jsonpError ) {}
|
||||
}
|
||||
|
||||
if ( head ) {
|
||||
head.removeChild( script );
|
||||
}
|
||||
@@ -444,8 +445,9 @@ jQuery.extend({
|
||||
|
||||
// Fire the complete handlers
|
||||
if ( !jsonp ) {
|
||||
jQuery.ajax.handleComplete( s, xhr, status, data );
|
||||
}
|
||||
jQuery.ajax.handleComplete( s, xhr, status, data );
|
||||
}
|
||||
|
||||
if ( isTimeout === "timeout" ) {
|
||||
xhr.abort();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user