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

Unified Diff: chrome/browser/chromeos/policy/device_local_account_policy_service.cc

Issue 756133002: Purge cache when the server removes the policy for an extension. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix win build Created 6 years 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: chrome/browser/chromeos/policy/device_local_account_policy_service.cc
diff --git a/chrome/browser/chromeos/policy/device_local_account_policy_service.cc b/chrome/browser/chromeos/policy/device_local_account_policy_service.cc
index e11a02f08a78ceab467e19cd19bac76f7e37259e..19a8f3bb6eead6c3e6b05e935a7ccbbee5eedcf4 100644
--- a/chrome/browser/chromeos/policy/device_local_account_policy_service.cc
+++ b/chrome/browser/chromeos/policy/device_local_account_policy_service.cc
@@ -173,11 +173,11 @@ void DeviceLocalAccountPolicyBroker::ConnectIfPossible(
if (!client)
return;
+ CreateComponentCloudPolicyService(request_context, client.get());
core_.Connect(client.Pass());
external_data_manager_->Connect(request_context);
core_.StartRefreshScheduler();
UpdateRefreshDelay();
- CreateComponentCloudPolicyService(request_context);
}
void DeviceLocalAccountPolicyBroker::UpdateRefreshDelay() {
@@ -213,7 +213,8 @@ void DeviceLocalAccountPolicyBroker::OnComponentCloudPolicyUpdated() {
}
void DeviceLocalAccountPolicyBroker::CreateComponentCloudPolicyService(
- const scoped_refptr<net::URLRequestContextGetter>& request_context) {
+ const scoped_refptr<net::URLRequestContextGetter>& request_context,
+ CloudPolicyClient* client) {
if (CommandLine::ForCurrentProcess()->HasSwitch(
switches::kDisableComponentCloudPolicy)) {
// Disabled via the command line.
@@ -229,6 +230,7 @@ void DeviceLocalAccountPolicyBroker::CreateComponentCloudPolicyService(
this,
&schema_registry_,
core(),
+ client,
resource_cache.Pass(),
request_context,
content::BrowserThread::GetMessageLoopProxyForThread(

Powered by Google App Engine
This is Rietveld 408576698