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

Unified Diff: trunk/src/chrome/browser/extensions/activity_log/activity_log.cc

Issue 23600024: Revert 222242 "[Activity Log] when extension is uninstalled, del..." (Closed) Base URL: svn://svn.chromium.org/chrome/
Patch Set: Created 7 years, 3 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
« no previous file with comments | « no previous file | trunk/src/chrome/browser/extensions/activity_log/activity_log_policy.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: trunk/src/chrome/browser/extensions/activity_log/activity_log.cc
===================================================================
--- trunk/src/chrome/browser/extensions/activity_log/activity_log.cc (revision 222255)
+++ trunk/src/chrome/browser/extensions/activity_log/activity_log.cc (working copy)
@@ -302,11 +302,6 @@
DependsOn(InstallTrackerFactory::GetInstance());
}
-// static
-ActivityLog* ActivityLog::GetInstance(Profile* profile) {
- return ActivityLogFactory::GetForProfile(profile);
-}
-
ActivityLogFactory::~ActivityLogFactory() {
}
@@ -451,17 +446,18 @@
void ActivityLog::OnExtensionUninstalled(const Extension* extension) {
// If the extension has been uninstalled but not disabled, we delete the
// database.
- if (extension->id() == kActivityLogExtensionId) {
- if (!CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kEnableExtensionActivityLogging)) {
- DeleteDatabase();
- }
- } else {
- if (policy_)
- policy_->RemoveExtensionData(extension->id());
+ if (extension->id() != kActivityLogExtensionId) return;
+ if (!CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kEnableExtensionActivityLogging)) {
+ DeleteDatabase();
}
}
+// static
+ActivityLog* ActivityLog::GetInstance(Profile* profile) {
+ return ActivityLogFactory::GetForProfile(profile);
+}
+
void ActivityLog::AddObserver(ActivityLog::Observer* observer) {
observers_->AddObserver(observer);
}
« no previous file with comments | « no previous file | trunk/src/chrome/browser/extensions/activity_log/activity_log_policy.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698