Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a9e460ae authored by Robin Lee's avatar Robin Lee
Browse files

Remove enforceManagedProfile for listing keyguard features

Change-Id: Ic89f09ada046f64b089b977868b6f37bc0a6de91
parent 38dfba03
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -2940,7 +2940,6 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub {
            return 0;
        }
        enforceCrossUserPermission(userHandle);
        enforceNotManagedProfile(userHandle, "list disabled keyguard features");
        synchronized (this) {
            if (who != null) {
                ActiveAdmin admin = getActiveAdminUncheckedLocked(who, userHandle);
@@ -3170,7 +3169,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub {

    private void enforceNotManagedProfile(int userHandle, String message) {
        if(isManagedProfile(userHandle)) {
            throw new SecurityException("You can not " + message + " from a managed profile. ");
            throw new SecurityException("You can not " + message + " for a managed profile. ");
        }
    }