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

Unified Diff: third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerContainer.cpp

Issue 2059953003: service worker: Fix the type of a register promise reject value (Closed) Base URL: https://chromium.googlesource.com/chromium/src@master
Patch Set: Use ServiceWorkerErrorForUpdate directly Created 4 years, 5 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
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/serviceworker/resources/registration-tests.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerContainer.cpp
diff --git a/third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerContainer.cpp b/third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerContainer.cpp
index efd57b705ecb0132efe521ca599154baee0085e0..8a213195804932dd5dfb365b65d393c44dd8132b 100644
--- a/third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerContainer.cpp
+++ b/third_party/WebKit/Source/modules/serviceworkers/ServiceWorkerContainer.cpp
@@ -76,10 +76,11 @@ public:
{
if (!m_resolver->getExecutionContext() || m_resolver->getExecutionContext()->activeDOMObjectsAreStopped())
return;
+ ScriptState::Scope scope(m_resolver->getScriptState());
if (error.errorType == WebServiceWorkerError::ErrorTypeType) {
m_resolver->reject(V8ThrowException::createTypeError(m_resolver->getScriptState()->isolate(), error.message));
} else {
- m_resolver->reject(ServiceWorkerError::take(m_resolver.get(), error));
+ m_resolver->reject(ServiceWorkerErrorForUpdate::take(m_resolver.get(), error));
}
}
« no previous file with comments | « third_party/WebKit/LayoutTests/http/tests/serviceworker/resources/registration-tests.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698