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

Unified Diff: content/browser/service_worker/service_worker_context_wrapper.cc

Issue 2610163002: PaymentApp: Implement InvokePaymentApp() in browser side. (Closed)
Patch Set: nhiroki's comments Created 3 years, 11 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/browser/service_worker/service_worker_context_wrapper.cc
diff --git a/content/browser/service_worker/service_worker_context_wrapper.cc b/content/browser/service_worker/service_worker_context_wrapper.cc
index 6c5881189fa43ed89a803e5713a44b2945f2cf9e..69ffa22cbfea8504f31ea41c8e37a9f4f9ebc2a3 100644
--- a/content/browser/service_worker/service_worker_context_wrapper.cc
+++ b/content/browser/service_worker/service_worker_context_wrapper.cc
@@ -711,6 +711,21 @@ void ServiceWorkerContextWrapper::FindReadyRegistrationForId(
this, callback));
}
+void ServiceWorkerContextWrapper::FindReadyRegistrationForIdOnly(
+ int64_t registration_id,
+ const FindRegistrationCallback& callback) {
+ DCHECK_CURRENTLY_ON(BrowserThread::IO);
+ if (!context_core_) {
+ // FindRegistrationForIdOnly() can run the callback synchronously.
+ callback.Run(SERVICE_WORKER_ERROR_ABORT, nullptr);
+ return;
+ }
+ context_core_->storage()->FindRegistrationForIdOnly(
+ registration_id,
+ base::Bind(&ServiceWorkerContextWrapper::DidFindRegistrationForFindReady,
+ this, callback));
+}
+
void ServiceWorkerContextWrapper::DidFindRegistrationForFindReady(
const FindRegistrationCallback& callback,
ServiceWorkerStatusCode status,

Powered by Google App Engine
This is Rietveld 408576698