Re: [slightlyoff/ServiceWorker] Why doesn't cache.match support `cacheName` (#917)

Yea, the spec defines a single `CacheQueryOptions` that can be used with:

* `caches.match()`
* `cache.match()`
* `cache.matchAll()`
* `cache.delete()`
* `cache.keys()`

The `cacheName` field only applies to the `caches.match()` though because in all other cases you are calling the method on a specific cache object already.

Also note that `cacheName` was recently changed to simply return `undefined` if the cache object cannot be found.  Previously this threw a TypeError.  Right now there are probably browsers in the wild that do both, so you want to be careful with `cacheName`.

---
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/917#issuecomment-228097311

Received on Thursday, 23 June 2016 15:59:49 UTC