mirror of
https://github.com/jquery/jquery.git
synced 2024-11-23 02:54:22 +00:00
The code for handling Ajax timeouts was broken (the abort was being called too early). Fixing this allows the test suite to work again.
This commit is contained in:
parent
ab551c2b14
commit
d81dfbcccf
@ -393,11 +393,12 @@ jQuery.extend({
|
||||
setTimeout(function(){
|
||||
// Check to see if the request is still happening
|
||||
if ( xhr ) {
|
||||
// Cancel the request
|
||||
xhr.abort();
|
||||
|
||||
if( !requestDone )
|
||||
onreadystatechange( "timeout" );
|
||||
|
||||
// Cancel the request
|
||||
if ( xhr )
|
||||
xhr.abort();
|
||||
}
|
||||
}, s.timeout);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user