Re: [ServiceWorker] Make FetchEvent.prototype.client nullable (#631)

> E.g. for sendBeacon() or ping="" there might no longer be a client environment to expose.

As the type of the _client_ concept is defined as an environment settings object. Either _null_ or _empty environment setting object_ seems to work here.

> Also consider the case of navigating to a URL controlled by the service worker. There's no client environment created to receive messages from until the service worker responds. In that case there cannot be a Client object either, right?

It's confusing. Although the client environment for this requested resource (client request) has not been created, shouldn't `FetchEvent.prototype.client` return a Client object that represents the event's request's client?

---
Reply to this email directly or view it on GitHub:
https://github.com/slightlyoff/ServiceWorker/issues/631#issuecomment-75712231

Received on Tuesday, 24 February 2015 07:42:21 UTC