Skip to content

Commit

Permalink
address review comments
Browse files Browse the repository at this point in the history
  • Loading branch information
cabanier committed Sep 16, 2022
1 parent 242cc22 commit abb965a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions index.bs
Expand Up @@ -241,7 +241,7 @@ Note: It is the responsibility of user agents to ensure that the physical origin
<div class="algorithm unstable" data-algorithm="restore-persistent-anchor-from-frame">
The {{XRSession/restorePersistentAnchor(uuid)}} method, when invoked on an {{XRSession}} |session| with |uuid|, MUST run the following steps:
1. Let |promise| be [=a new Promise=] in the [=relevant realm=] of this {{XRSystem}}.
1. If |session|'s [=XRSession/map of persistent anchors=] does not contain a mapping, [=/reject=] |promise| with {{InvalidStateError}}, return |promise|, and abort these steps.
1. If |session|'s [=XRSession/map of persistent anchors=] does not contain a mapping from |uuid| to an {{XRAnchor}}, [=/reject=] |promise| with {{InvalidStateError}}, return |promise|, and abort these steps.
1. If |session|’s [=ended=] value is `true`, [=/reject=] |promise| with {{InvalidStateError}}, return |promise|, and abort these steps.
1. Let |anchor| be the value of mapping from |uuid| on |session|'s [=XRSession/map of persistent anchors=].
1. If |session|'s [=XRSession/map of new anchors=] contains a mapping from |anchor| to |promise|, [=/reject=] the |promise| with {{InvalidStateError}}, return |promise|, and abort these steps.
Expand All @@ -253,8 +253,8 @@ The {{XRSession/restorePersistentAnchor(uuid)}} method, when invoked on an {{XRS
<div class="algorithm unstable" data-algorithm="delete-peristence-from-anchor">
The {{XRSession/deletePersistentAnchor()}} method, when invoked on an {{XRSession}} |session| with |uuid|, MUST run the following steps:
1. Let |promise| be [=a new Promise=] in the [=relevant realm=] of this {{XRSystem}}.
1. Let |anchor| be the value of mapping from |uuid| on |session|'s [=XRSession/map of persistent anchors=].
1. If |session|'s [=XRSession/map of persistent anchors=] does not contain a mapping to |anchor|, [=/reject=] |promise| with {{InvalidStateError}}, return |promise|, and abort these steps.
1. Let |anchor| be the value of mapping from |uuid| on |session|'s [=XRSession/map of persistent anchors=].
1. Remove the mapping from |session|'s [=XRSession/map of persistent anchors=].
1. Invoke {{XRAnchor/delete()} on |anchor|.
1. Return |promise|.
Expand Down

0 comments on commit abb965a

Please sign in to comment.