Service Worker: in Unregister, wait until after the active worker no longer controls a document
As per spec: https://slightlyoff.github.io/ServiceWorker/spec/service_worker/index.html#unregister-algorithm
Unregister shouldn't doom the active worker or delete the registration until
the active worker no longer controls a document. This means that if register()
is called before that happens, the unregistration is effectively canceled.
BUG=388095
TEST=https://codereview.chromium.org/
416003003/
Review URL: https://codereview.chromium.org/
413063004
Cr-Commit-Position: refs/heads/master@{#288994}
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@288994 0039d316-1c4b-4281-b951-d872f2087c98