Commit eba09588 authored by Svet Ganov's avatar Svet Ganov
Browse files

Properly show third-party defined permission in platform groups

Apps can define permissions in the platform groups. If a legacy app
deifines a permission in a platform group we were showing the permission
twice because we failed to group the custom permission in the platform
group when building the UI.

bug:26142772

Change-Id: I263bff8631e14395c9000e5e54b0e160969e1eb2
parent 3f07e658
......@@ -136,9 +136,9 @@ public final class AppPermissionGroup implements Comparable<AppPermissionGroup>
continue;
}
// Don't allow toggle of non platform defined permissions for legacy apps via app ops.
// Don't allow toggling non-platform permission groups for legacy apps via app ops.
if (packageInfo.applicationInfo.targetSdkVersion <= Build.VERSION_CODES.LOLLIPOP_MR1
&& !PLATFORM_PACKAGE_NAME.equals(requestedPermissionInfo.packageName)) {
&& !PLATFORM_PACKAGE_NAME.equals(groupInfo.packageName)) {
continue;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment