Skip to content

Commit 15facb9

Browse files
committed
Updating service worker flag to enum & also fixes #362
1 parent 0e18173 commit 15facb9

File tree

1 file changed

+9
-10
lines changed

1 file changed

+9
-10
lines changed

fetch.bs

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -728,11 +728,9 @@ explicitly set <a for=/>request</a>'s
728728
this flag set are subject to additional processing requirements.
729729

730730
<p>A <a for=/>request</a> has an associated
731-
<dfn export>skip-service-worker flag</dfn>. Unless stated otherwise it is
732-
unset.
733-
734-
<p>A <a for=/>request</a> has an associated <dfn export>skip-local-service-worker flag</dfn>. Unless
735-
stated otherwise it is unset.
731+
<dfn export>use-service-workers value</dfn>, that is "<code>all</code>",
732+
"<code>foreign</code>", or "<code>none</code>". Unless stated otherwise it is
733+
"<code>all</code>".
736734

737735
<p>A <a for=/>request</a> has an associated
738736
<dfn export for=request id=concept-request-initiator>initiator</dfn>, which is
@@ -2796,13 +2794,13 @@ optional <i>CORS flag</i> and <i>CORS-preflight flag</i>, run these steps:
27962794
<li><p>Let <var>actualResponse</var> be null.
27972795

27982796
<li>
2799-
<p>If <var>request</var>'s <a>skip-service-worker flag</a> is unset, then run these
2797+
<p>If <var>request</var>'s <a>use-service-workers value</a> is not "<code>none</code>", then run these
28002798
substeps:
28012799

28022800
<ol>
28032801
<li>
28042802
<p>If <var>request</var>'s <a for=request>client</a> is null or
2805-
<var>request</var>'s <a>skip-local-service-worker flag</a> is unset, then set
2803+
<var>request</var>'s <a>use-service-workers value</a> is "<code>all</code>", then set
28062804
<var>response</var> to the result of invoking <a for=/>handle fetch</a> for <var>request</var>.
28072805
[[!HTML]] [[!SW]]
28082806

@@ -2894,7 +2892,8 @@ optional <i>CORS flag</i> and <i>CORS-preflight flag</i>, run these steps:
28942892

28952893
<li>
28962894
<p>If <var>request</var>'s <a for=request>redirect mode</a> is
2897-
"<code>follow</code>", then set <var>request</var>'s <a>skip-service-worker flag</a>.
2895+
"<code>follow</code>", then set <var>request</var>'s <a>use-service-workers value</a> to
2896+
"<code>none</code>".
28982897

28992898
<p class="note no-backref">Redirects coming from the network (as opposed to from a service
29002899
worker) are not to be exposed to a service worker.
@@ -5170,7 +5169,7 @@ method, must run these steps:
51705169

51715170
<li>If <var>request</var>'s <a for=request>client</a>'s
51725171
<a for="environment settings object">global object</a> is a {{ServiceWorkerGlobalScope}} object,
5173-
set <var>request</var>'s <a>skip-local-service-worker flag</a>.
5172+
set <var>request</var>'s <a>use-service-workers value</a> to "<code>foreign</code>".
51745173

51755174
<li><p>Let <var>responseObject</var> be a new {{Response}} object and a new associated
51765175
{{Headers}} object whose <a for=Headers>guard</a> is
@@ -5323,7 +5322,7 @@ therefore not shareable, a WebSocket connection is very close to identical to an
53235322
<li><p>Let <var>request</var> be a new <a for=/>request</a>, whose
53245323
<a for=request>url</a> is <var>requestURL</var>,
53255324
<a for=request>client</a> is <var>client</var>,
5326-
<a>skip-service-worker flag</a> is set,
5325+
<a>use-service-workers value</a> is "<code>none</code>",
53275326
<a>synchronous flag</a> is set,
53285327
<a for=request>mode</a> is "<code>websocket</code>",
53295328
<a for=request>credentials mode</a> is

0 commit comments

Comments
 (0)