diff --git a/services/core/java/com/android/server/am/UserController.java b/services/core/java/com/android/server/am/UserController.java index f1bad98193948..d1126ee1bf1c5 100644 --- a/services/core/java/com/android/server/am/UserController.java +++ b/services/core/java/com/android/server/am/UserController.java @@ -1307,7 +1307,7 @@ class UserController implements Handler.Callback { Slog.w(TAG, "No user info for user #" + userId); return false; } - if (foreground && userInfo.isManagedProfile()) { + if (foreground && userInfo.isProfile()) { Slog.w(TAG, "Cannot switch to User #" + userId + ": not a full user"); return false; } @@ -1612,7 +1612,7 @@ class UserController implements Handler.Callback { Slog.w(TAG, "Cannot switch to User #" + targetUserId + ": not supported"); return false; } - if (targetUserInfo.isManagedProfile()) { + if (targetUserInfo.isProfile()) { Slog.w(TAG, "Cannot switch to User #" + targetUserId + ": not a full user"); return false; }