()
| 155 | |
| 156 | // Returns response’s URL, if it has one; otherwise the empty string. |
| 157 | get url () { |
| 158 | webidl.brandCheck(this, Response) |
| 159 | |
| 160 | const urlList = this.#state.urlList |
| 161 | |
| 162 | // The url getter steps are to return the empty string if this’s |
| 163 | // response’s URL is null; otherwise this’s response’s URL, |
| 164 | // serialized with exclude fragment set to true. |
| 165 | const url = urlList[urlList.length - 1] ?? null |
| 166 | |
| 167 | if (url === null) { |
| 168 | return '' |
| 169 | } |
| 170 | |
| 171 | return URLSerializer(url, true) |
| 172 | } |
| 173 | |
| 174 | // Returns whether response was obtained through a redirect. |
| 175 | get redirected () { |
nothing calls this directly
no test coverage detected