Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(317)

Unified Diff: content/child/service_worker/service_worker_dispatcher.cc

Issue 1186803002: ServiceWorker: Route unregister() through WebServiceWorkerRegistration for refactoring (4) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@route_web_sw_reg_2
Patch Set: rebase Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: content/child/service_worker/service_worker_dispatcher.cc
diff --git a/content/child/service_worker/service_worker_dispatcher.cc b/content/child/service_worker/service_worker_dispatcher.cc
index 37d8484fa046615603fbae22145902b5a492043f..f28058180def3d1f97f9ab60bf13d43e43dc17e5 100644
--- a/content/child/service_worker/service_worker_dispatcher.cc
+++ b/content/child/service_worker/service_worker_dispatcher.cc
@@ -136,34 +136,6 @@ void ServiceWorkerDispatcher::UpdateServiceWorker(int provider_id,
provider_id, registration_id));
}
-void ServiceWorkerDispatcher::DeprecatedUnregisterServiceWorker(
- int provider_id,
- const GURL& pattern,
- WebServiceWorkerUnregistrationCallbacks* callbacks) {
- DCHECK(callbacks);
-
- if (pattern.possibly_invalid_spec().size() > GetMaxURLChars()) {
- scoped_ptr<WebServiceWorkerUnregistrationCallbacks>
- owned_callbacks(callbacks);
- std::string error_message(kServiceWorkerUnregisterErrorPrefix);
- error_message += "The provided scope is too long.";
- scoped_ptr<WebServiceWorkerError> error(
- new WebServiceWorkerError(WebServiceWorkerError::ErrorTypeSecurity,
- blink::WebString::fromUTF8(error_message)));
- callbacks->onError(error.release());
- return;
- }
-
- int request_id = pending_unregistration_callbacks_.Add(callbacks);
- TRACE_EVENT_ASYNC_BEGIN1("ServiceWorker",
- "ServiceWorkerDispatcher::UnregisterServiceWorker",
- request_id,
- "Scope", pattern.spec());
- thread_safe_sender_->Send(
- new ServiceWorkerHostMsg_DeprecatedUnregisterServiceWorker(
- CurrentWorkerId(), request_id, provider_id, pattern));
-}
-
void ServiceWorkerDispatcher::UnregisterServiceWorker(
int provider_id,
int64 registration_id,

Powered by Google App Engine
This is Rietveld 408576698