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

Unified Diff: chrome/browser/supervised_user/child_accounts/child_account_service.cc

Issue 785893003: Adapt Chrome OS related part of ChildAccountService. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: User type check removed. Created 6 years 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/ui/ash/system_tray_delegate_chromeos.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/supervised_user/child_accounts/child_account_service.cc
diff --git a/chrome/browser/supervised_user/child_accounts/child_account_service.cc b/chrome/browser/supervised_user/child_accounts/child_account_service.cc
index 95ee22533d173017bf3bac3d3d3ffc758a3e4fad..c6a4ed29f149f677c111c806c47d343df99e661d 100644
--- a/chrome/browser/supervised_user/child_accounts/child_account_service.cc
+++ b/chrome/browser/supervised_user/child_accounts/child_account_service.cc
@@ -251,16 +251,15 @@ void ChildAccountService::SetIsChildAccount(bool is_child_account) {
void ChildAccountService::PropagateChildStatusToUser(bool is_child) {
#if defined(OS_CHROMEOS)
- // TODO(merkulova,treib): Figure out why this causes tests to fail.
-// user_manager::User* user =
-// chromeos::ProfileHelper::Get()->GetUserByProfile(profile_);
-// if (user) {
-// user_manager::UserManager::Get()->ChangeUserSupervisedStatus(
-// user, is_child);
-// } else {
-// LOG(WARNING) <<
-// "User instance wasn't found while setting child account flag.";
-// }
+ user_manager::User* user =
+ chromeos::ProfileHelper::Get()->GetUserByProfile(profile_);
+ if (user) {
+ user_manager::UserManager::Get()->ChangeUserSupervisedStatus(
+ user, is_child);
+ } else {
+ LOG(WARNING) <<
+ "User instance wasn't found while setting child account flag.";
+ }
#endif
}
« no previous file with comments | « no previous file | chrome/browser/ui/ash/system_tray_delegate_chromeos.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698