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

Unified Diff: chrome/browser/chromeos/login/signin/auth_sync_observer.cc

Issue 393343002: Rename "managed (mode|user)" to "supervised user" (part 7) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: more alphabetize (and rebase again) Created 6 years, 5 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/signin/auth_sync_observer.cc
diff --git a/chrome/browser/chromeos/login/signin/auth_sync_observer.cc b/chrome/browser/chromeos/login/signin/auth_sync_observer.cc
index a0ed887a34280b67158758029c6188b9a60e848f..c2ced0b0203df3c9e87e6c8fbdb9a8ed4f6e6486 100644
--- a/chrome/browser/chromeos/login/signin/auth_sync_observer.cc
+++ b/chrome/browser/chromeos/login/signin/auth_sync_observer.cc
@@ -45,7 +45,7 @@ void AuthSyncObserver::Shutdown() {
void AuthSyncObserver::OnStateChanged() {
DCHECK(UserManager::Get()->IsLoggedInAsRegularUser() ||
- UserManager::Get()->IsLoggedInAsLocallyManagedUser());
+ UserManager::Get()->IsLoggedInAsSupervisedUser());
ProfileSyncService* sync_service =
ProfileSyncServiceFactory::GetForProfile(profile_);
User* user = ProfileHelper::Get()->GetUserByProfile(profile_);
@@ -66,7 +66,7 @@ void AuthSyncObserver::OnStateChanged() {
User::OAuthTokenStatus old_status = user->oauth_token_status();
UserManager::Get()->SaveUserOAuthStatus(email,
User::OAUTH2_TOKEN_STATUS_INVALID);
- if (user->GetType() == user_manager::USER_TYPE_LOCALLY_MANAGED &&
+ if (user->GetType() == user_manager::USER_TYPE_SUPERVISED &&
old_status != User::OAUTH2_TOKEN_STATUS_INVALID) {
// Attempt to restore token from file.
UserManager::Get()->GetSupervisedUserManager()->LoadSupervisedUserToken(
@@ -77,7 +77,7 @@ void AuthSyncObserver::OnStateChanged() {
base::UserMetricsAction("ManagedUsers_Chromeos_Sync_Invalidated"));
}
} else if (state == GoogleServiceAuthError::NONE) {
- if (user->GetType() == user_manager::USER_TYPE_LOCALLY_MANAGED &&
+ if (user->GetType() == user_manager::USER_TYPE_SUPERVISED &&
user->oauth_token_status() == User::OAUTH2_TOKEN_STATUS_INVALID) {
LOG(ERROR) <<
"Got an incorrectly invalidated token case, restoring token status.";

Powered by Google App Engine
This is Rietveld 408576698