From e94b1312326bc8122b09ab7bf5c2b1339947dc9d Mon Sep 17 00:00:00 2001 From: Adam Bookatz Date: Mon, 19 Oct 2020 12:16:23 -0700 Subject: [PATCH] Change a few UserController calls to use isProfile These should be isProfile instead of isManagedProfile. Right now, there is no practical difference, but it could be useful later. Test: N/A (it's a no-op) Bug: 170249807 Change-Id: I32d0c8d1c209f0f1e3c95c4b2911f6d12ed2c804 --- services/core/java/com/android/server/am/UserController.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/services/core/java/com/android/server/am/UserController.java b/services/core/java/com/android/server/am/UserController.java index eb60573e6f17e..b5be037f7ea9e 100644 --- a/services/core/java/com/android/server/am/UserController.java +++ b/services/core/java/com/android/server/am/UserController.java @@ -1309,7 +1309,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; } @@ -1614,7 +1614,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; }