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

Unified Diff: chrome/browser/chromeos/login/managed/locally_managed_user_login_flow.cc

Issue 33173005: Correctly deal with tokens for supervised users in ProfileOAuth2TokenService. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix Created 7 years, 1 month 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
« no previous file with comments | « no previous file | chrome/browser/extensions/api/identity/account_tracker.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/chromeos/login/managed/locally_managed_user_login_flow.cc
diff --git a/chrome/browser/chromeos/login/managed/locally_managed_user_login_flow.cc b/chrome/browser/chromeos/login/managed/locally_managed_user_login_flow.cc
index 380d1d6ec07abf9b8f873371ed77aa60f8147122..bbc928ad0c46165430bcc78815e176a4092a738d 100644
--- a/chrome/browser/chromeos/login/managed/locally_managed_user_login_flow.cc
+++ b/chrome/browser/chromeos/login/managed/locally_managed_user_login_flow.cc
@@ -71,13 +71,16 @@ void LocallyManagedUserLoginFlow::HandleOAuthTokenStatusChange(
void LocallyManagedUserLoginFlow::OnSyncSetupDataLoaded(
const std::string& token) {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
- // TODO(antrim): add error handling (no token loaded).
ConfigureSync(token);
}
void LocallyManagedUserLoginFlow::ConfigureSync(const std::string& token) {
data_loaded_ = true;
- ManagedUserServiceFactory::GetForProfile(profile_)->InitSync(token);
+ // TODO(antrim): add error handling (no token loaded).
+ // See also: http://crbug.com/312751
+ if (!token.empty())
+ ManagedUserServiceFactory::GetForProfile(profile_)->InitSync(token);
+
LoginUtils::Get()->DoBrowserLaunch(profile_, host());
profile_ = NULL;
UnregisterFlowSoon();
« no previous file with comments | « no previous file | chrome/browser/extensions/api/identity/account_tracker.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698