Skip to content
This repository has been archived by the owner on Jan 23, 2021. It is now read-only.

Make the SW more resilient to caches being manually cleared. #186

Merged
merged 1 commit into from Sep 20, 2016

Conversation

jeffposnick
Copy link
Contributor

R: @gauntface @addyosmani

Fixes #185

If the user manually clears the contents of Cache Storage, but doesn't unregister the SW, then sw-precache would get into a bad state, where it didn't properly fall back to the network. This fixes that bug.

(Deep down, I knew that cache.match() resolves with undefined rather than rejecting when it doesn't match, but it's so easy to forget...)

@addyosmani addyosmani merged commit 65852ec into master Sep 20, 2016
@addyosmani addyosmani deleted the cache-clear-resilience branch September 20, 2016 22:47
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Deleted cache, FetchEvent error response
3 participants