| Index: chrome/browser/profiles/profile_impl.cc
|
| diff --git a/chrome/browser/profiles/profile_impl.cc b/chrome/browser/profiles/profile_impl.cc
|
| index 6eb96e9124b0403f2162ae6a12ebe790e1d9cee6..c6c8c6ed6659e33402ec48756fb45d4fa5c99f88 100644
|
| --- a/chrome/browser/profiles/profile_impl.cc
|
| +++ b/chrome/browser/profiles/profile_impl.cc
|
| @@ -777,8 +777,8 @@ bool ProfileImpl::IsSupervised() {
|
|
|
| bool ProfileImpl::IsChild() {
|
| #if defined(ENABLE_SUPERVISED_USERS)
|
| - return GetPrefs()->GetString(prefs::kSupervisedUserId) ==
|
| - supervised_users::kChildAccountSUID;
|
| + return user_manager::UserID::FromUserEmail(GetPrefs()->GetString(prefs::kSupervisedUserId)) ==
|
| + supervised_users::GetChildAccountSUID();
|
| #else
|
| return false;
|
| #endif
|
| @@ -1159,8 +1159,8 @@ void ProfileImpl::ChangeAppLocale(
|
| if (via != APP_LOCALE_CHANGED_VIA_PUBLIC_SESSION_LOGIN)
|
| local_state->SetString(prefs::kApplicationLocale, new_locale);
|
|
|
| - if (user_manager::UserManager::Get()->GetOwnerEmail() ==
|
| - chromeos::ProfileHelper::Get()->GetUserByProfile(this)->email())
|
| + if (user_manager::UserManager::Get()->GetOwnerID() ==
|
| + chromeos::ProfileHelper::Get()->GetUserByProfile(this)->GetUserID())
|
| local_state->SetString(prefs::kOwnerLocale, new_locale);
|
| }
|
|
|
| @@ -1231,8 +1231,8 @@ void ProfileImpl::UpdateProfileSupervisedUserIdCache() {
|
| ProfileInfoCache& cache = profile_manager->GetProfileInfoCache();
|
| size_t index = cache.GetIndexOfProfileWithPath(GetPath());
|
| if (index != std::string::npos) {
|
| - std::string supervised_user_id =
|
| - GetPrefs()->GetString(prefs::kSupervisedUserId);
|
| + const user_manager::UserID supervised_user_id(
|
| + user_manager::UserID::FromUserEmail(GetPrefs()->GetString(prefs::kSupervisedUserId)));
|
| cache.SetSupervisedUserIdOfProfileAtIndex(index, supervised_user_id);
|
| ProfileMetrics::UpdateReportedProfilesStatistics(profile_manager);
|
| }
|
|
|