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

Unified Diff: google_apis/gaia/ubertoken_fetcher.cc

Issue 1129463004: Let Ubertoken Fetch be primed with an access token. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rogerta's comments Created 5 years, 7 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: google_apis/gaia/ubertoken_fetcher.cc
diff --git a/google_apis/gaia/ubertoken_fetcher.cc b/google_apis/gaia/ubertoken_fetcher.cc
index 15e5932bed620498fe8ede7fc2cd6ad2369c987d..10f2ba286859188146ba5a634159e0dde2f77802 100644
--- a/google_apis/gaia/ubertoken_fetcher.cc
+++ b/google_apis/gaia/ubertoken_fetcher.cc
@@ -43,6 +43,17 @@ void UbertokenFetcher::StartFetchingToken(const std::string& account_id) {
RequestAccessToken();
}
+void UbertokenFetcher::StartFetchingTokenWithAccessToken(
+ const std::string& account_id, const std::string& access_token) {
+ DCHECK(!account_id.empty());
+ if (access_token.empty())
Andrew T Wilson (Slow) 2015/05/11 10:06:21 Adding a DCHECK() then handling this case seems ba
Roger Tawa OOO till Jul 10th 2015/05/11 16:56:16 This code is DCHECKing one thing and handling anot
Andrew T Wilson (Slow) 2015/05/12 15:08:08 Ah, you are right, I missed that one was checking
Mike Lerman 2015/05/12 20:51:44 Changed this method so that it should always have
+ StartFetchingToken(account_id);
xiyuan 2015/05/11 16:11:58 Should we return here to let access token fetching
Mike Lerman 2015/05/12 20:51:44 I no longer permit access_token.empty(). The calle
+
+ account_id_ = account_id;
+ access_token_ = access_token;
+ ExchangeTokens();
+}
+
void UbertokenFetcher::OnUberAuthTokenSuccess(const std::string& token) {
consumer_->OnUbertokenSuccess(token);
}
« google_apis/gaia/ubertoken_fetcher.h ('K') | « google_apis/gaia/ubertoken_fetcher.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698