self.close(xhr); 这里会有异常: this.close is not a function 不需要关闭吗

文字缩进4格``文字缩进4格 var xhr = new XMLHttpRequest();
var self = this;
xhr.onreadystatechange = function () {
if (xhr.readyState == 4) {
} else {
}
};
xhr.timeout = 10000;
xhr.onerror = function (err) {
};
xhr.ontimeout = function () {
self.close(xhr);
};
xhr.responseType = “arraybuffer”;
xhr.open(“GET”, address, true);
xhr.send();

为啥 self.close(xhr); 这里会有异常: this.close is not a function 不需要关闭吗