[slightlyoff/ServiceWorker] should ServiceWorkerContainer.getRegistrations() check the uninstalling flag (#943)

Currently we set the uninstalling flag when an unregister job runs but we can't remove the registration yet.  For example, its still controlling a client.  This flag is then used to hide the registration when someone calls `navigator.serviceWorker.getRegistration()`.

We don't, however, check the uninstalling flag in `navigator.serviceWorker.getRegistrations()`.  So an uninstalling registration will show up there.

Is this intentional?  It seems very confusing to me that the registration for your scope might show up in `getRegistrations()`, but not `getRegistration()`.  I would expect them to have similar logic.

Note, an uninstalling registration will still be exposed via `self.registration` in the service worker thread itself.

---
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/943

Received on Friday, 5 August 2016 08:44:15 UTC