Index: chrome/browser/extensions/unpacked_installer.cc |
diff --git a/chrome/browser/extensions/unpacked_installer.cc b/chrome/browser/extensions/unpacked_installer.cc |
index 1a41314a5c92d070d3baec247d5a7d8590a3c9dc..867c183b49e87872f8567ad848ee85534bf9cdc6 100644 |
--- a/chrome/browser/extensions/unpacked_installer.cc |
+++ b/chrome/browser/extensions/unpacked_installer.cc |
@@ -285,32 +285,19 @@ void UnpackedInstaller::LoadWithFileAccess(int flags) { |
return; |
} |
- // The installation prompt is about to be shown, which means we're past the |
- // point of detecting installation errors. We can now safely remove the retry |
- // handler that listens for them. |
- BrowserThread::PostTask( |
- BrowserThread::UI, |
- FROM_HERE, |
- base::Bind(&UnpackedInstaller::UnregisterLoadRetryListener, this)); |
- |
BrowserThread::PostTask( |
BrowserThread::UI, |
FROM_HERE, |
base::Bind(&UnpackedInstaller::ShowInstallPrompt, this)); |
} |
-void UnpackedInstaller::UnregisterLoadRetryListener() { |
- CHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
- if (!service_weak_.get()) |
- return; |
- service_weak_->NotifyLoadRetry(false, extension_path_); |
-} |
- |
void UnpackedInstaller::ReportExtensionLoadError(const std::string &error) { |
CHECK(BrowserThread::CurrentlyOn(BrowserThread::UI)); |
- if (!service_weak_.get()) |
- return; |
- service_weak_->ReportExtensionLoadError(extension_path_, error, true); |
+ if (!on_failure_callback_.is_null()) |
+ on_failure_callback_.Run(extension_path_, error); |
+ |
+ if (service_weak_.get()) |
+ service_weak_->ReportExtensionLoadError(extension_path_, error); |
} |
void UnpackedInstaller::ConfirmInstall() { |