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

Unified Diff: chrome/browser/chromeos/login/oauth2_login_verifier.cc

Issue 23382008: Making OAuth2TokenService multi-login aware, updating callers, minor fixes (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebasing to include the update to ProfileSyncService: r224220 Created 7 years, 3 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/chromeos/login/oauth2_login_verifier.cc
diff --git a/chrome/browser/chromeos/login/oauth2_login_verifier.cc b/chrome/browser/chromeos/login/oauth2_login_verifier.cc
index 8ade58bfc37371f7200b72f4cac4f98f859d57b8..603b50690ca8494da58605bfddf90bfd7a09fad7 100644
--- a/chrome/browser/chromeos/login/oauth2_login_verifier.cc
+++ b/chrome/browser/chromeos/login/oauth2_login_verifier.cc
@@ -76,9 +76,13 @@ void OAuth2LoginVerifier::VerifyProfileTokens(Profile* profile) {
void OAuth2LoginVerifier::StartFetchingOAuthLoginAccessToken(Profile* profile) {
OAuth2TokenService::ScopeSet scopes;
scopes.insert(GaiaUrls::GetInstance()->oauth1_login_scope());
- login_token_request_ = ProfileOAuth2TokenServiceFactory::
- GetForProfile(profile)->StartRequestWithContext(
- system_request_context_.get(), scopes, this);
+ ProfileOAuth2TokenService* token_service =
+ ProfileOAuth2TokenServiceFactory::GetForProfile(profile);
+ login_token_request_ = token_service->StartRequestWithContext(
+ token_service->GetPrimaryAccountId(),
+ system_request_context_.get(),
+ scopes,
+ this);
}
void OAuth2LoginVerifier::StartOAuthLoginForUberToken() {

Powered by Google App Engine
This is Rietveld 408576698