Commit df15d864 authored by sdefresne's avatar sdefresne Committed by Commit bot

Fix global variable name to follow style guide

BUG=None

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

Cr-Commit-Position: refs/heads/master@{#308325}
parent 604cc60d
...@@ -31,19 +31,19 @@ ...@@ -31,19 +31,19 @@
// to find the associated web::BrowserState (there is a 1:1 mapping). // to find the associated web::BrowserState (there is a 1:1 mapping).
namespace { namespace {
BrowserStateFromContextFn gBrowserStateFromContext = nullptr; BrowserStateFromContextFn g_browser_state_from_context = nullptr;
} // namespace } // namespace
void SetBrowserStateFromContextHelper(BrowserStateFromContextFn helper) { void SetBrowserStateFromContextHelper(BrowserStateFromContextFn helper) {
gBrowserStateFromContext = helper; g_browser_state_from_context = helper;
} }
web::BrowserState* BrowserStateFromContext(base::SupportsUserData* context) { web::BrowserState* BrowserStateFromContext(base::SupportsUserData* context) {
web::BrowserState* state = nullptr; web::BrowserState* state = nullptr;
if (context) { if (context) {
state = web::BrowserState::FromSupportsUserData(context); state = web::BrowserState::FromSupportsUserData(context);
if (!state && gBrowserStateFromContext) if (!state && g_browser_state_from_context)
state = gBrowserStateFromContext(context); state = g_browser_state_from_context(context);
DCHECK(state) << "cannot convert context to web::BrowserState"; DCHECK(state) << "cannot convert context to web::BrowserState";
} }
return state; return state;
......
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