- s.complete = [function() {
-
- // Set callback back to previous value
- window[ jsonpCallback ] = previous;
-
- // Call if it was a function and we have a response
- if ( previous) {
- if ( responseContainer && jQuery.isFunction ( previous ) ) {
- window[ jsonpCallback ] ( responseContainer[0] );
- }
- } else {
- // else, more memory leak avoidance
- try{ delete window[ jsonpCallback ]; } catch(e){}
- }
-
- }, s.complete ];
+ // Install cleanUp function
+ jqXHR.then( cleanUp, cleanUp );