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

Unified Diff: chrome/browser/extensions/extension_sync_service.cc

Issue 405433003: Apps&Extensions for supervised users: Allow the custodian to remotely uninstall extensions. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: other UNINSTALL_REASON_SYNC occurrences Created 6 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: chrome/browser/extensions/extension_sync_service.cc
diff --git a/chrome/browser/extensions/extension_sync_service.cc b/chrome/browser/extensions/extension_sync_service.cc
index 82d93bba1a73a2eb40bf4bad26160e517294d339..a0a13c375383b3408fbd03f14e82218d65cbc576 100644
--- a/chrome/browser/extensions/extension_sync_service.cc
+++ b/chrome/browser/extensions/extension_sync_service.cc
@@ -449,10 +449,13 @@ bool ExtensionSyncService::ProcessExtensionSyncDataHelper(
// Handle uninstalls first.
if (extension_sync_data.uninstalled()) {
- if (!extension_service_->UninstallExtensionHelper(
- extension_service_, id, ExtensionService::UNINSTALL_REASON_SYNC)) {
- LOG(WARNING) << "Could not uninstall extension " << id
- << " for sync";
+ ExtensionService::UninstallReason reason =
+ extension_sync_data.installed_by_custodian() ?
+ ExtensionService::UNINSTALL_REASON_SYNC_BY_CUSTODIAN :
+ ExtensionService::UNINSTALL_REASON_SYNC;
+ if (!extension_service_->UninstallExtensionHelper(extension_service_,
+ id, reason)) {
+ LOG(WARNING) << "Could not uninstall extension " << id << " for sync";
}
return true;
}

Powered by Google App Engine
This is Rietveld 408576698