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

Unified Diff: third_party/WebKit/Source/web/ServiceWorkerGlobalScopeProxy.cpp

Issue 2116503004: Make Foreign Fetch an origin trial. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Check for correct RuntimeEnabledFeatures to determine which features were installed. 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
Index: third_party/WebKit/Source/web/ServiceWorkerGlobalScopeProxy.cpp
diff --git a/third_party/WebKit/Source/web/ServiceWorkerGlobalScopeProxy.cpp b/third_party/WebKit/Source/web/ServiceWorkerGlobalScopeProxy.cpp
index abfa8f85f7898f49e6f46faad8a9ec90756846cd..eb8ce52c5d523786efd37ca10ae417d71787b459 100644
--- a/third_party/WebKit/Source/web/ServiceWorkerGlobalScopeProxy.cpp
+++ b/third_party/WebKit/Source/web/ServiceWorkerGlobalScopeProxy.cpp
@@ -37,6 +37,7 @@
#include "core/dom/ExecutionContext.h"
#include "core/dom/MessagePort.h"
#include "core/inspector/ConsoleMessage.h"
+#include "core/origin_trials/OriginTrials.h"
#include "core/workers/WorkerGlobalScope.h"
#include "core/workers/WorkerThread.h"
#include "modules/background_sync/SyncEvent.h"
@@ -177,7 +178,7 @@ void ServiceWorkerGlobalScopeProxy::dispatchInstallEvent(int eventID)
{
WaitUntilObserver* observer = WaitUntilObserver::create(workerGlobalScope(), WaitUntilObserver::Install, eventID);
Event* event;
- if (RuntimeEnabledFeatures::foreignFetchEnabled())
+ if (OriginTrials::foreignFetchEnabled(workerGlobalScope()))
event = InstallEvent::create(EventTypeNames::install, ExtendableEventInit(), observer);
else
event = ExtendableEvent::create(EventTypeNames::install, ExtendableEventInit(), observer);

Powered by Google App Engine
This is Rietveld 408576698