mirror of
https://github.com/electron/electron.git
synced 2026-01-25 07:18:18 -05:00
Fix usages of global BrowserContext in App::ImportCertificate
This commit is contained in:
@@ -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<base::DictionaryValue> copy = options.CreateDeepCopy();
|
||||
CertificateManagerModel::Create(browser_context,
|
||||
CertificateManagerModel::Create(
|
||||
browser_context.get(),
|
||||
base::Bind(&App::OnCertificateManagerModelCreated,
|
||||
base::Unretained(this),
|
||||
base::Passed(©),
|
||||
|
||||
Reference in New Issue
Block a user