Skip to content
Permalink
Browse files

-8 bytes

  • Loading branch information...
markelog committed May 3, 2012
1 parent 9cb1ab4 commit bab6f5355cf8a02e1789d27d62defd78a7cdb1f4
Showing with 5 additions and 6 deletions.
  1. +5 −6 src/ajax.js
@@ -165,10 +165,9 @@ jQuery.fn.extend({
return this;
}

var selector, type,
var selector, type, response,
self = this,
off = url.indexOf(" "),
response;
off = url.indexOf(" ");

if ( off >= 0 ) {
selector = url.slice( off, url.length );
@@ -197,13 +196,13 @@ jQuery.fn.extend({
data: params,
complete: function( jqXHR, status ) {
if ( callback ) {
self.each( callback, [ status === "success" ? response : jqXHR.responseText, status, jqXHR ] );
self.each( callback, response || [ jqXHR.responseText, status, jqXHR ] );
}
}
}).done(function( responseText ) {

// Save response text for use in complete callback
response = responseText;
// Save response for use in complete callback
response = arguments;

// See if a selector was specified
self.html( selector ?

0 comments on commit bab6f53

Please sign in to comment.
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.