Ajax: remove use of jQuery#each second argument

Ref gh-2090
This commit is contained in:
Oleg Gaidarenko 2015-02-17 10:05:25 +03:00
parent 8356281bed
commit a4715f4216

View File

@ -70,7 +70,9 @@ jQuery.fn.load = function( url, params, callback ) {
// but they are ignored because response was set above.
// If it fails, this function gets "jqXHR", "status", "error"
}).always( callback && function( jqXHR, status ) {
self.each( callback, response || [ jqXHR.responseText, status, jqXHR ] );
self.each( function() {
callback.apply( self, response || [ jqXHR.responseText, status, jqXHR ] );
});
});
}