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

Unified Diff: chrome/browser/ui/sync/one_click_signin_sync_starter.cc

Issue 479353003: Add IsAuthenticated() method to SigninManager. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address review comments Created 6 years, 4 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
« no previous file with comments | « chrome/browser/ui/chrome_pages.cc ('k') | chrome/browser/ui/views/profiles/profile_chooser_view.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/sync/one_click_signin_sync_starter.cc
diff --git a/chrome/browser/ui/sync/one_click_signin_sync_starter.cc b/chrome/browser/ui/sync/one_click_signin_sync_starter.cc
index 3a6d7f122372734ee2a5ce26c1b2ea3ef82747ef..5952be3f7357dda54b6f4d5e5880d14396696c61 100644
--- a/chrome/browser/ui/sync/one_click_signin_sync_starter.cc
+++ b/chrome/browser/ui/sync/one_click_signin_sync_starter.cc
@@ -153,7 +153,7 @@ void OneClickSigninSyncStarter::ConfirmSignin(const std::string& oauth_token) {
SigninManager* signin = SigninManagerFactory::GetForProfile(profile_);
// If this is a new signin (no authenticated username yet) try loading
// policy for this user now, before any signed in services are initialized.
- if (signin->GetAuthenticatedUsername().empty()) {
+ if (!signin->IsAuthenticated()) {
#if defined(ENABLE_CONFIGURATION_POLICY)
policy::UserPolicySigninService* policy_service =
policy::UserPolicySigninServiceFactory::GetForProfile(profile_);
@@ -302,8 +302,8 @@ void OneClickSigninSyncStarter::CompleteInitForNewProfile(
SigninManager* new_signin_manager =
SigninManagerFactory::GetForProfile(new_profile);
DCHECK(!old_signin_manager->GetUsernameForAuthInProgress().empty());
- DCHECK(old_signin_manager->GetAuthenticatedUsername().empty());
- DCHECK(new_signin_manager->GetAuthenticatedUsername().empty());
+ DCHECK(!old_signin_manager->IsAuthenticated());
+ DCHECK(!new_signin_manager->IsAuthenticated());
DCHECK(!dm_token_.empty());
DCHECK(!client_id_.empty());
« no previous file with comments | « chrome/browser/ui/chrome_pages.cc ('k') | chrome/browser/ui/views/profiles/profile_chooser_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698