| Index: chrome/browser/policy/browser_policy_connector.cc
|
| diff --git a/chrome/browser/policy/browser_policy_connector.cc b/chrome/browser/policy/browser_policy_connector.cc
|
| index 073f8d9df3b95d7f940d3078ba09292d3d3e22b5..6453eca8380a646ca2480f8e4faf1b9bee3e4ee4 100644
|
| --- a/chrome/browser/policy/browser_policy_connector.cc
|
| +++ b/chrome/browser/policy/browser_policy_connector.cc
|
| @@ -530,27 +530,25 @@ void BrowserPolicyConnector::InitializeDevicePolicy() {
|
| device_data_store_.reset();
|
|
|
| CommandLine* command_line = CommandLine::ForCurrentProcess();
|
| - if (command_line->HasSwitch(switches::kEnableDevicePolicy)) {
|
| - if (command_line->HasSwitch(switches::kEnableCloudPolicyService)) {
|
| - // TODO(mnissler): Initialize new-style device policy here once it's
|
| - // implemented.
|
| - } else {
|
| - device_data_store_.reset(CloudPolicyDataStore::CreateForDevicePolicies());
|
| - chromeos::CryptohomeLibrary* cryptohome =
|
| - chromeos::CrosLibrary::Get()->GetCryptohomeLibrary();
|
| - install_attributes_.reset(new EnterpriseInstallAttributes(cryptohome));
|
| - DevicePolicyCache* device_policy_cache =
|
| - new DevicePolicyCache(device_data_store_.get(),
|
| - install_attributes_.get());
|
| -
|
| - managed_cloud_provider_->SetDevicePolicyCache(device_policy_cache);
|
| - recommended_cloud_provider_->SetDevicePolicyCache(device_policy_cache);
|
| -
|
| - device_cloud_policy_subsystem_.reset(new CloudPolicySubsystem(
|
| - device_data_store_.get(),
|
| - device_policy_cache,
|
| - GetDeviceManagementUrl()));
|
| - }
|
| + if (command_line->HasSwitch(switches::kEnableCloudPolicyService)) {
|
| + // TODO(mnissler): Initialize new-style device policy here once it's
|
| + // implemented.
|
| + } else {
|
| + device_data_store_.reset(CloudPolicyDataStore::CreateForDevicePolicies());
|
| + chromeos::CryptohomeLibrary* cryptohome =
|
| + chromeos::CrosLibrary::Get()->GetCryptohomeLibrary();
|
| + install_attributes_.reset(new EnterpriseInstallAttributes(cryptohome));
|
| + DevicePolicyCache* device_policy_cache =
|
| + new DevicePolicyCache(device_data_store_.get(),
|
| + install_attributes_.get());
|
| +
|
| + managed_cloud_provider_->SetDevicePolicyCache(device_policy_cache);
|
| + recommended_cloud_provider_->SetDevicePolicyCache(device_policy_cache);
|
| +
|
| + device_cloud_policy_subsystem_.reset(new CloudPolicySubsystem(
|
| + device_data_store_.get(),
|
| + device_policy_cache,
|
| + GetDeviceManagementUrl()));
|
| }
|
| #endif
|
| }
|
|
|