mirror of
https://github.com/Jermolene/TiddlyWiki5
synced 2024-07-06 20:14:22 +00:00
Further fixes to cancelling outstanding HTTP requests
This commit is contained in:
parent
cc7b857d71
commit
09e626e8ab
|
@ -65,9 +65,11 @@ HttpClient.prototype.initiateHttpRequest = function(options) {
|
||||||
|
|
||||||
HttpClient.prototype.cancelAllHttpRequests = function() {
|
HttpClient.prototype.cancelAllHttpRequests = function() {
|
||||||
var self = this;
|
var self = this;
|
||||||
for(var t=this.requests.length - 1; t--; t>=0) {
|
if(this.requests.length > 0) {
|
||||||
var requestInfo = this.requests[t];
|
for(var t=this.requests.length - 1; t--; t>=0) {
|
||||||
requestInfo.request.cancel();
|
var requestInfo = this.requests[t];
|
||||||
|
requestInfo.request.cancel();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
this.requests = [];
|
this.requests = [];
|
||||||
this.updateRequestTracker();
|
this.updateRequestTracker();
|
||||||
|
|
Loading…
Reference in New Issue
Block a user