diff --git a/index.html b/index.html index d1f2444..1064de3 100644 --- a/index.html +++ b/index.html @@ -171,9 +171,10 @@

NotFoundError, SecurityError, and steps for constructing - events are defined in [[!DOM]]. + "http://www.w3.org/TR/dom/#securityerror">SecurityError, + NetworkError, + and steps for + constructing events are defined in [[!DOM]].

Service Worker, ServiceWorkerRegistration, @@ -441,9 +442,6 @@

Promise<PushRegistration> register ()
-
- Promise<PushRegistration> unregister () -
Promise<PushRegistration> getRegistration ()
@@ -505,31 +503,6 @@

has not yet been defined in a specification, this document currently links to the bug for defining it.

-

- The unregister - method when invoked MUST run the following steps: -

-
    -
  1. Let promise be a new Promise. -
  2. -
  3. Return promise and continue the following steps asynchronously. -
  4. -
  5. If the webapp is not registered, reject promise with a - DOMException whose name is "NotFoundError" and - terminate these steps. -
  6. -
  7. Make a request to the system to deactivate the push registration associated with - the webapp. -
  8. -
  9. If there is an error, reject promise with a DOMException - whose name is "AbortError" and terminate these steps. -
  10. -
  11. When the request has been completed, resolve promise with a - PushRegistration providing the details of the push registration - which has been unregistered. -
  12. -

The getRegistration @@ -644,6 +617,9 @@

readonly attribute DOMString registrationId
+
+ Promise<boolean> unregister () +

When getting the endpoint @@ -662,6 +638,28 @@

registrationId and endpoint is expected to be unique and specific to a particular webapp instance running on a specific device.

+

+ The unregister method when + invoked MUST run the following steps: +

+
    +
  1. Let promise be a new Promise. +
  2. +
  3. Return promise and continue the following steps asynchronously. +
  4. +
  5. If the webapp is not registered, resolve promise with + false and terminate these steps. +
  6. +
  7. Make a request to the system to deactivate the push registration associated with + the webapp. +
  8. +
  9. If it was not possible to access the push server, reject promise with + a "NetworkError" exception and terminate these steps. +
  10. +
  11. When the request has been completed, resolve promise with true. +
  12. +