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

Commit 21c84e94 authored by Nate Myren's avatar Nate Myren
Browse files

Remove temporary exceptions from notification dialog code

Now that pregrants are in place, these lines are no longer needed

Test: manual
Bug: 194833441
Change-Id: Ibf6359c217b04c00ebc01080a2b7e51f06f741ba
parent 2e6243d9
Loading
Loading
Loading
Loading
+3 −5
Original line number Diff line number Diff line
@@ -1139,13 +1139,11 @@ public final class PermissionPolicyService extends SystemService {
        private boolean shouldForceShowNotificationPermissionRequest(@NonNull String pkgName,
                @NonNull UserHandle user) {
            AndroidPackage pkg = mPackageManagerInternal.getPackage(pkgName);
            // TODO(b/205888750): Remove platform key and permissionController lines after pregrants
            // are in place
            if (pkg == null || pkg.getPackageName() == null || pkg.isSignedWithPlatformKey()
                    || pkg.getPackageName().contains("nexuslauncher")
            if (pkg == null || pkg.getPackageName() == null
                    || Objects.equals(pkgName, mPackageManager.getPermissionControllerPackageName())
                    || pkg.getTargetSdkVersion() < Build.VERSION_CODES.M) {
                // TODO(b/205888750) add warning logs when pregrants in place
                Slog.w(LOG_TAG, "Cannot check for Notification prompt, no package for "
                        + pkgName + " or pkg is Permission Controller");
                return false;
            }