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

Unified Diff: third_party/WebKit/Source/modules/background_sync/SyncCallbacks.cpp

Issue 2433773006: Remove ExecutionContext::activeDOMObjectsAreStopped()
Patch Set: Created 4 years, 2 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: third_party/WebKit/Source/modules/background_sync/SyncCallbacks.cpp
diff --git a/third_party/WebKit/Source/modules/background_sync/SyncCallbacks.cpp b/third_party/WebKit/Source/modules/background_sync/SyncCallbacks.cpp
index c66fedb771f6193ac10c1e0ba8e5d9fb6c5fc8e8..c9c3c7840131a96fb0513fae404b8e0058ee3139 100644
--- a/third_party/WebKit/Source/modules/background_sync/SyncCallbacks.cpp
+++ b/third_party/WebKit/Source/modules/background_sync/SyncCallbacks.cpp
@@ -25,10 +25,8 @@ SyncRegistrationCallbacks::~SyncRegistrationCallbacks() {}
void SyncRegistrationCallbacks::onSuccess(
std::unique_ptr<WebSyncRegistration> webSyncRegistration) {
- if (!m_resolver->getExecutionContext() ||
- m_resolver->getExecutionContext()->activeDOMObjectsAreStopped()) {
+ if (!m_resolver->getExecutionContext())
return;
- }
std::unique_ptr<WebSyncRegistration> registration =
wrapUnique(webSyncRegistration.release());
@@ -40,10 +38,8 @@ void SyncRegistrationCallbacks::onSuccess(
}
void SyncRegistrationCallbacks::onError(const WebSyncError& error) {
- if (!m_resolver->getExecutionContext() ||
- m_resolver->getExecutionContext()->activeDOMObjectsAreStopped()) {
+ if (!m_resolver->getExecutionContext())
return;
- }
m_resolver->reject(SyncError::take(m_resolver.get(), error));
}
@@ -60,10 +56,8 @@ SyncGetRegistrationsCallbacks::~SyncGetRegistrationsCallbacks() {}
void SyncGetRegistrationsCallbacks::onSuccess(
const WebVector<WebSyncRegistration*>& webSyncRegistrations) {
- if (!m_resolver->getExecutionContext() ||
- m_resolver->getExecutionContext()->activeDOMObjectsAreStopped()) {
+ if (!m_resolver->getExecutionContext())
return;
- }
Vector<String> tags;
for (const WebSyncRegistration* r : webSyncRegistrations) {
tags.append(r->tag);
@@ -72,10 +66,8 @@ void SyncGetRegistrationsCallbacks::onSuccess(
}
void SyncGetRegistrationsCallbacks::onError(const WebSyncError& error) {
- if (!m_resolver->getExecutionContext() ||
- m_resolver->getExecutionContext()->activeDOMObjectsAreStopped()) {
+ if (!m_resolver->getExecutionContext())
return;
- }
m_resolver->reject(SyncError::take(m_resolver.get(), error));
}

Powered by Google App Engine
This is Rietveld 408576698