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

Commit 4da326c0 authored by Andrew Sapperstein's avatar Andrew Sapperstein
Browse files

Revert "Update checking of flag MATCH_HIDDEN_UNTIL_INSTALLED_COMPONENTS"

This reverts commit 44c4ca41.

Reason for revert: Wanted to go with a different option and this was mistakenly Dr. No'ed.

Bug: 80444486
Test: clean revert
Change-Id: I7fdd13a5bc0f4d9fabf91f3e5497c4065008b531
parent 44c4ca41
Loading
Loading
Loading
Loading
+3 −7
Original line number Diff line number Diff line
@@ -95,7 +95,6 @@ import com.android.internal.annotations.VisibleForTesting;
import com.android.internal.os.ClassLoaderFactory;
import com.android.internal.util.ArrayUtils;
import com.android.internal.util.XmlUtils;
import com.android.server.SystemConfig;

import libcore.io.IoUtils;
import libcore.util.EmptyArray;
@@ -641,12 +640,9 @@ public class PackageParser {
    private static boolean checkUseInstalledOrHidden(int flags, PackageUserState state,
            ApplicationInfo appInfo) {
        // Returns false if the package is hidden system app until installed.
        final ArraySet<String> hiddenSystemApps =
                SystemConfig.getInstance().getDisabledUntilUsedPreinstalledCarrierApps();
        if (!state.installed
                && appInfo != null && appInfo.isSystemApp()
                && hiddenSystemApps.contains(appInfo.packageName)
                && (flags & PackageManager.MATCH_HIDDEN_UNTIL_INSTALLED_COMPONENTS) == 0) {
        if ((flags & PackageManager.MATCH_HIDDEN_UNTIL_INSTALLED_COMPONENTS) == 0
                && !state.installed
                && appInfo != null && appInfo.isSystemApp()) {
            return false;
        }