Commit a7cbc07a authored by voodoo's avatar voodoo Committed by Commit bot

Terminated extensions should be uninstalled without error now.

For extensions that have been terminated, attempts to uninstall them via the chrome.management.uninstall call
caused an "Extension not found" error because such extensions weren't included in the search.

R=rockot@chromium.org
BUG=412252

Review URL: https://codereview.chromium.org/556723003

Cr-Commit-Position: refs/heads/master@{#293906}
parent 30b38742
......@@ -599,7 +599,8 @@ bool ManagementUninstallFunctionBase::Uninstall(
bool show_confirm_dialog) {
extension_id_ = target_extension_id;
const Extension* target_extension =
service()->GetExtensionById(extension_id_, true);
extensions::ExtensionRegistry::Get(browser_context())->
GetExtensionById(extension_id_, ExtensionRegistry::EVERYTHING);
if (!target_extension ||
ui_util::ShouldNotBeVisible(target_extension, browser_context())) {
error_ = ErrorUtils::FormatErrorMessage(
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment