summaryrefslogtreecommitdiffstats
path: root/toolkit/components/url-classifier/tests/mochitest/sw_unregister.html
blob: b94fa0baac1f5a17df6e662fa199e1ae93094eac (plain)
1
2
3
4
5
6
7
8
9
10
11
12
<!DOCTYPE html>
<script>
  navigator.serviceWorker.getRegistration(".").then(function(registration) {
    registration.unregister().then(function(success) {
      if (success) {
        window.opener.postMessage({status: "unregistrationdone"}, "*");
      }
    }, function(e) {
      dump("Unregistering the SW failed with " + e + "\n");
    });
  });
</script>