- From: Ben Kelly <notifications@github.com>
- Date: Fri, 18 Mar 2016 14:27:44 -0700
- To: slightlyoff/ServiceWorker <ServiceWorker@noreply.github.com>
Received on Friday, 18 March 2016 21:28:14 UTC
The Install algorithm has this currently
```
14) If registration’s waiting worker is not null, then:
  1) Terminate registration’s waiting worker.
  2) Run the Update State algorithm passing registration’s waiting worker and
       redundant as the arguments.
  3) The user agent may abort in-flight requests triggered by registration’s waiting worker. 
15) Set registration’s waiting worker to registration’s installing worker. 
```
It seems the `statechange` event triggered by 14.2 Update State might see the redundant worker still set as `registration.waiting`.  Most other instances of Update State change the registration attribute first.
As a side note, should the `statechange` event see the new service worker in registration.waiting or a null .waiting?
---
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/slightlyoff/ServiceWorker/issues/851
Received on Friday, 18 March 2016 21:28:14 UTC