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

Unified Diff: chrome/browser/extensions/api/dashboard_private/dashboard_private_api.cc

Issue 1864583006: Simplify BrowserContext by removing redundant methods. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix Created 4 years, 8 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
Index: chrome/browser/extensions/api/dashboard_private/dashboard_private_api.cc
diff --git a/chrome/browser/extensions/api/dashboard_private/dashboard_private_api.cc b/chrome/browser/extensions/api/dashboard_private/dashboard_private_api.cc
index 146a6f93370ba676cc44bcd7ea6673dd3eb8f636..7f75beddf347ef18f1aef29bacc955cddbd79d1d 100644
--- a/chrome/browser/extensions/api/dashboard_private/dashboard_private_api.cc
+++ b/chrome/browser/extensions/api/dashboard_private/dashboard_private_api.cc
@@ -11,6 +11,7 @@
#include "chrome/browser/bitmap_fetcher/bitmap_fetcher.h"
#include "chrome/browser/profiles/profile.h"
#include "components/crx_file/id_util.h"
+#include "content/public/browser/storage_partition.h"
#include "extensions/common/extension.h"
#include "net/base/load_flags.h"
#include "net/url_request/url_request.h"
@@ -74,8 +75,11 @@ DashboardPrivateShowPermissionPromptForDelegatedInstallFunction::Run() {
}
net::URLRequestContextGetter* context_getter = nullptr;
- if (!icon_url.is_empty())
- context_getter = browser_context()->GetRequestContext();
+ if (!icon_url.is_empty()) {
+ context_getter =
+ content::BrowserContext::GetDefaultStoragePartition(browser_context())->
+ GetURLRequestContext();
+ }
scoped_refptr<WebstoreInstallHelper> helper = new WebstoreInstallHelper(
this, params_->details.id, params_->details.manifest, icon_url,

Powered by Google App Engine
This is Rietveld 408576698