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

Unified Diff: chrome/browser/ui/webui/sync_setup_handler.cc

Issue 10335015: Treat SyncCredentialsLost as an auth error (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 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: chrome/browser/ui/webui/sync_setup_handler.cc
diff --git a/chrome/browser/ui/webui/sync_setup_handler.cc b/chrome/browser/ui/webui/sync_setup_handler.cc
index c3b95dae6377da510be8e331aa066d00ce050026..5a1a63375252efe929a55e3d5567898ce0248cd4 100644
--- a/chrome/browser/ui/webui/sync_setup_handler.cc
+++ b/chrome/browser/ui/webui/sync_setup_handler.cc
@@ -872,7 +872,7 @@ void SyncSetupHandler::OpenSyncSetup(bool force_login) {
// There are several different UI flows that can bring the user here:
// 1) Signin promo (passes force_login=true)
- // 2) Normal signin through options page (AreCredentialsAvailable() will
+ // 2) Normal signin through options page (IsSyncEnabledAndLoggedIn() will
// return false).
// 3) Previously working credentials have expired
// (service->GetAuthError() != NONE).
@@ -885,7 +885,8 @@ void SyncSetupHandler::OpenSyncSetup(bool force_login) {
// 7) ChromeOS re-enable after disabling sync.
#if !defined(OS_CHROMEOS)
if (force_login ||
- !service->AreCredentialsAvailable() ||
+ !service->IsSyncEnabledAndLoggedIn() ||
+ !service->IsSyncTokenAvailable() ||
Nicolas Zea 2012/05/15 23:39:04 Do we want to check the token here? Presumably if
Andrew T Wilson (Slow) 2012/05/16 01:05:16 It shouldn't matter if we check both or not (and i
service->GetAuthError().state() != GoogleServiceAuthError::NONE) {
// User is not logged in, or login has been specially requested - need to
// display login UI (cases 1-4).

Powered by Google App Engine
This is Rietveld 408576698