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

Unified Diff: chrome/browser/extensions/api/identity/gaia_web_auth_flow.cc

Issue 1220963005: Update base::StartsWith calls to new form (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@starts_with
Patch Set: Created 5 years, 6 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/identity/gaia_web_auth_flow.cc
diff --git a/chrome/browser/extensions/api/identity/gaia_web_auth_flow.cc b/chrome/browser/extensions/api/identity/gaia_web_auth_flow.cc
index 3301db86448f4d0e82116b81afaae273834a5da4..6b7232ed00587a25d0e687e6a6a903595793af4a 100644
--- a/chrome/browser/extensions/api/identity/gaia_web_auth_flow.cc
+++ b/chrome/browser/extensions/api/identity/gaia_web_auth_flow.cc
@@ -179,7 +179,8 @@ void GaiaWebAuthFlow::OnAuthFlowURLChange(const GURL& url) {
// interpreted as a path, including the fragment.
if (url.scheme() == redirect_scheme_ && !url.has_host() && !url.has_port() &&
- base::StartsWithASCII(url.GetContent(), redirect_path_prefix_, true)) {
+ base::StartsWith(url.GetContent(), redirect_path_prefix_,
+ base::CompareCase::SENSITIVE)) {
web_flow_.release()->DetachDelegateAndDelete();
std::string fragment = url.GetContent().substr(
@@ -223,7 +224,7 @@ void GaiaWebAuthFlow::OnAuthFlowTitleChange(const std::string& title) {
const char kRedirectPrefix[] = "Loading ";
std::string prefix(kRedirectPrefix);
- if (base::StartsWithASCII(title, prefix, true)) {
+ if (base::StartsWith(title, prefix, base::CompareCase::SENSITIVE)) {
GURL url(title.substr(prefix.length(), std::string::npos));
if (url.is_valid())
OnAuthFlowURLChange(url);

Powered by Google App Engine
This is Rietveld 408576698