Prevent firing _onStreamProgress after aborting

pull/633/head
Omar Roth 6 years ago
parent 6a6cf015a6
commit cc6d6ddd66
No known key found for this signature in database
GPG Key ID: B8254FB7EC3D37F2

@ -94,7 +94,7 @@ var SSE = function (url, options) {
}
this._onStreamProgress = function(e) {
if (this.xhr.status !== 200) {
if (this.xhr.status !== 200 && this.readyState !== this.CLOSED) {
this._onStreamFailure(e);
return;
}

Loading…
Cancel
Save