File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed
Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -509,11 +509,12 @@ exports.XMLHttpRequest = function() {
509509 * Called when an error is encountered to deal with it.
510510 */
511511 this . handleError = function ( error ) {
512- this . status = 503 ;
512+ this . status = 0 ;
513513 this . statusText = error ;
514514 this . responseText = error . stack ;
515515 errorFlag = true ;
516516 setState ( this . DONE ) ;
517+ this . dispatchEvent ( 'error' ) ;
517518 } ;
518519
519520 /**
@@ -526,6 +527,7 @@ exports.XMLHttpRequest = function() {
526527 }
527528
528529 headers = defaultHeaders ;
530+ this . status = 0 ;
529531 this . responseText = "" ;
530532 this . responseXML = "" ;
531533
@@ -538,6 +540,7 @@ exports.XMLHttpRequest = function() {
538540 setState ( this . DONE ) ;
539541 }
540542 this . readyState = this . UNSENT ;
543+ this . dispatchEvent ( 'abort' ) ;
541544 } ;
542545
543546 /**
You can’t perform that action at this time.
0 commit comments