- From: Anne van Kesteren <notifications@github.com>
- Date: Thu, 10 Nov 2022 05:45:29 -0800
- To: whatwg/fetch <fetch@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <whatwg/fetch/pull/1481/review/1175803751@github.com>
@annevk commented on this pull request.
Right, I agree we can expose this as-is. `Content-Type` is a safelisted response header when it comes to CORS.
> @@ -346,6 +346,9 @@ following <a for=struct>items</a>: [[RESOURCE-TIMING]] [[NAVIGATION-TIMING]]
<dt><dfn export for="response body info" id="fetch-timing-info-decoded-body-size">decoded
size</dfn> (default 0)
<dd>A number.
+<dt><dfn export for="response body info" id="response-body-info-content-type">content
Nit: indentation.
> @@ -346,6 +346,9 @@ following <a for=struct>items</a>: [[RESOURCE-TIMING]] [[NAVIGATION-TIMING]]
<dt><dfn export for="response body info" id="fetch-timing-info-decoded-body-size">decoded
size</dfn> (default 0)
<dd>A number.
+<dt><dfn export for="response body info" id="response-body-info-content-type">content
+ type</dfn> (default empty string)
+ <dd>A string.
I don't think extracting a MIME type returns a string.
> @@ -4518,6 +4521,14 @@ steps:
<var>response</var>'s <a for=response>has-cross-origin-redirects</a> is true; otherwise
<var>response</var>'s <a for=response>status</a>.
+ <li><p>Set <a for=response>body info</a>'s <a for="response body info">content type</a> to the
+ empty string if <var>response</var>'s <a for=response>type</a> is "<code>opaque</code>" or
As with the other check we probably don't need to check "opaque" here as "opaque" responses won't have a `Content-Type` header anyway? (Unless you poke at its internals, which we're not doing here if I remember correctly.)
--
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/fetch/pull/1481#pullrequestreview-1175803751
You are receiving this because you are subscribed to this thread.
Message ID: <whatwg/fetch/pull/1481/review/1175803751@github.com>
Received on Thursday, 10 November 2022 13:45:41 UTC