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

Commit d9ab0d29 authored by Pavel Grafov's avatar Pavel Grafov
Browse files

Clean up fully rolled out AllowScreenBrightnessControlOnCope

Flag was rolled out in Android V.

Bug: 335663055
Test: TH
Flag: EXEMPT flag cleanup
Change-Id: I18f5e6faa7f950ebec9cafabc960216f529cae97
parent cc862807
Loading
Loading
Loading
Loading
+0 −7
Original line number Diff line number Diff line
@@ -245,13 +245,6 @@ flag {
  }
}

flag {
  name: "allow_screen_brightness_control_on_cope"
  namespace: "enterprise"
  description: "Allow COPE admin to control screen brightness and timeout."
  bug: "323894620"
}

flag {
  name: "always_persist_do"
  namespace: "enterprise"
+2 −2
Original line number Diff line number Diff line
@@ -15219,7 +15219,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub {
        final CallerIdentity caller = getCallerIdentity(who);
        Preconditions.checkCallAuthorization(
                isProfileOwner(caller) || isDefaultDeviceOwner(caller));
        if (Flags.allowScreenBrightnessControlOnCope() && parent) {
        if (parent) {
            Preconditions.checkCallAuthorization(isProfileOwnerOfOrganizationOwnedDevice(caller));
        }
        checkCanExecuteOrThrowUnsafe(DevicePolicyManager.OPERATION_SET_SYSTEM_SETTING);
@@ -15230,7 +15230,7 @@ public class DevicePolicyManagerService extends IDevicePolicyManager.Stub {
                        "Permission denial: device owners cannot update %1$s", setting));
            }
            int affectedUser;
            if (Flags.allowScreenBrightnessControlOnCope() && parent) {
            if (parent) {
                affectedUser = getProfileParentId(caller.getUserId());
            } else {
                affectedUser = caller.getUserId();