diff options
| author | Yasin Kilicdere <tyk@google.com> | 2022-02-01 19:46:05 +0000 |
|---|---|---|
| committer | Yasin Kilicdere <tyk@google.com> | 2022-02-02 17:43:45 +0000 |
| commit | 7ac52f42d2e46c8ae8e63f07f6d9fdc87ac02bdc (patch) | |
| tree | 957a4ce98cf35ed566a81ef7d734ec6e5de5b8b7 /core/java/android/os/UserManager.java | |
| parent | 7315b7278c0663fe53ecaab3f423e0a411197498 (diff) | |
Remove allowedToRemoveOne boolean parameter from UM.getRemainingCreatableProfileCount()
Bug: 217364189
Test: atest android.multiuser.cts.UserManagerTest
Change-Id: Idebeab6407eb90967dcd0ebbcfaba4b76a8f1263
Diffstat (limited to 'core/java/android/os/UserManager.java')
| -rw-r--r-- | core/java/android/os/UserManager.java | 9 |
1 files changed, 2 insertions, 7 deletions
diff --git a/core/java/android/os/UserManager.java b/core/java/android/os/UserManager.java index 7b8d34b3b570..2bd1dbb238e8 100644 --- a/core/java/android/os/UserManager.java +++ b/core/java/android/os/UserManager.java @@ -4055,9 +4055,6 @@ public class UserManager { * <p>Note that is applicable to any profile type (currently not including Restricted profiles). * * @param userType the type of profile, such as {@link UserManager#USER_TYPE_PROFILE_MANAGED}. - * @param allowedToRemoveOne whether removing an existing profile of given type -if there is- - * from the context user to make up space should be taken into account - * for the calculation. * @return how many additional profiles can be created. * @hide */ @@ -4068,13 +4065,11 @@ public class UserManager { android.Manifest.permission.QUERY_USERS }) @UserHandleAware - public int getRemainingCreatableProfileCount(@NonNull String userType, - boolean allowedToRemoveOne) { + public int getRemainingCreatableProfileCount(@NonNull String userType) { Objects.requireNonNull(userType, "userType must not be null"); try { // TODO(b/142482943): Perhaps let the following code apply to restricted users too. - return mService.getRemainingCreatableProfileCount(userType, mUserId, - allowedToRemoveOne); + return mService.getRemainingCreatableProfileCount(userType, mUserId); } catch (RemoteException re) { throw re.rethrowFromSystemServer(); } |
