simplify sw unregister

main
Mike Fix 6 years ago
parent afa63c3653
commit 27f8e1c7b6

@ -46,13 +46,7 @@ class Index extends React.Component {
function onReset() { function onReset() {
clearSettings() clearSettings()
if (window.navigator && navigator.serviceWorker) { unregister()
navigator.serviceWorker.getRegistrations().then(registrations => {
for (let registration of registrations) {
registration.unregister()
}
})
}
} }
export default withRouter(Index) export default withRouter(Index)

Loading…
Cancel
Save