(response, requestFragment)
| 5265 | } |
| 5266 | __name(responseURL, "responseURL"); |
| 5267 | function responseLocationURL(response, requestFragment) { |
| 5268 | if (!redirectStatusSet.has(response.status)) { |
| 5269 | return null; |
| 5270 | } |
| 5271 | let location = response.headersList.get("location", true); |
| 5272 | if (location !== null && isValidHeaderValue(location)) { |
| 5273 | if (!isValidEncodedURL(location)) { |
| 5274 | location = normalizeBinaryStringToUtf8(location); |
| 5275 | } |
| 5276 | location = new URL(location, responseURL(response)); |
| 5277 | } |
| 5278 | if (location && !location.hash) { |
| 5279 | location.hash = requestFragment; |
| 5280 | } |
| 5281 | return location; |
| 5282 | } |
| 5283 | __name(responseLocationURL, "responseLocationURL"); |
| 5284 | function isValidEncodedURL(url) { |
| 5285 | for (let i = 0; i < url.length; ++i) { |
no test coverage detected