(method, url)
| 27 | } |
| 28 | |
| 29 | open(method, url) { |
| 30 | this.method = method; |
| 31 | if (!url) { |
| 32 | url = location.href; |
| 33 | } else { |
| 34 | url = util.trim(url); |
| 35 | if (url.indexOf("http") !== 0) { |
| 36 | // Normalize the request url |
| 37 | if (isBrowser) { |
| 38 | let t = document.createElement("a"); |
| 39 | t.href = url; |
| 40 | url = t.href; |
| 41 | } |
| 42 | } |
| 43 | } |
| 44 | this.responseURL = url; |
| 45 | this._changeReadyState(1) |
| 46 | } |
| 47 | |
| 48 | send(arg) { |
| 49 | arg = arg || null; |
no test coverage detected