| Index: content/browser/service_worker/service_worker_version.cc
|
| diff --git a/content/browser/service_worker/service_worker_version.cc b/content/browser/service_worker/service_worker_version.cc
|
| index 66ca8830756abe28ea8e8b848c9ece3a822a8e9d..0bcec8983900ca78b5beb9bd25191707c4c7138b 100644
|
| --- a/content/browser/service_worker/service_worker_version.cc
|
| +++ b/content/browser/service_worker/service_worker_version.cc
|
| @@ -88,8 +88,10 @@ ServiceWorkerVersion::ServiceWorkerVersion(
|
| registration_id_(kInvalidServiceWorkerVersionId),
|
| status_(NEW),
|
| context_(context),
|
| + script_cache_map_(this),
|
| weak_factory_(this) {
|
| DCHECK(context_);
|
| + DCHECK(registration);
|
| if (registration) {
|
| registration_id_ = registration->id();
|
| script_url_ = registration->script_url();
|
| @@ -550,20 +552,6 @@ void ServiceWorkerVersion::OnSyncEventFinished(
|
| sync_callbacks_.Remove(request_id);
|
| }
|
|
|
| -void ServiceWorkerVersion::AddToScriptCache(
|
| - const GURL& url, int64 resource_id) {
|
| - DCHECK_EQ(kInvalidServiceWorkerResponseId, LookupInScriptCache(url));
|
| - DCHECK_EQ(NEW, status_);
|
| - script_cache_map_[url] = resource_id;
|
| -}
|
| -
|
| -int64 ServiceWorkerVersion::LookupInScriptCache(const GURL& url) {
|
| - ResourceIDMap::const_iterator found = script_cache_map_.find(url);
|
| - if (found == script_cache_map_.end())
|
| - return kInvalidServiceWorkerResponseId;
|
| - return found->second;
|
| -}
|
| -
|
| void ServiceWorkerVersion::OnPostMessageToDocument(
|
| int client_id,
|
| const base::string16& message,
|
|
|