diff --git a/atom/browser/api/atom_api_app.cc b/atom/browser/api/atom_api_app.cc index bc29b988eeea..265ed8f36b7d 100644 --- a/atom/browser/api/atom_api_app.cc +++ b/atom/browser/api/atom_api_app.cc @@ -463,10 +463,11 @@ void App::DisableHardwareAcceleration(mate::Arguments* args) { void App::ImportCertificate( const base::DictionaryValue& options, const net::CompletionCallback& callback) { - auto browser_context = AtomBrowserMainParts::Get()->browser_context(); + auto browser_context = brightray::BrowserContext::From("", false); if (!certificate_manager_model_) { std::unique_ptr copy = options.CreateDeepCopy(); - CertificateManagerModel::Create(browser_context, + CertificateManagerModel::Create( + browser_context.get(), base::Bind(&App::OnCertificateManagerModelCreated, base::Unretained(this), base::Passed(©),