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

Commit c4bfcd92 authored by TYM Tsai's avatar TYM Tsai
Browse files

Enable freezer metrics without flag

Bug: 321139675
Flag: android.content.pm.improve_install_freeze
Test: atest PackageInstallationSessionReportedStatsTests
Change-Id: I31f94197b0b4450bfa300881cbff1fb221547284
parent d86c1436
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -16,7 +16,6 @@

package com.android.server.pm;

import static android.content.pm.Flags.improveInstallFreeze;
import static android.content.pm.PackageInstaller.SessionParams.USER_ACTION_UNSPECIFIED;
import static android.content.pm.PackageManager.INSTALL_REASON_UNKNOWN;
import static android.content.pm.PackageManager.INSTALL_SCENARIO_DEFAULT;
@@ -1050,13 +1049,13 @@ final class InstallRequest {
    }

    public void onFreezeStarted() {
        if (mPackageMetrics != null && improveInstallFreeze()) {
        if (mPackageMetrics != null) {
            mPackageMetrics.onStepStarted(PackageMetrics.STEP_FREEZE_INSTALL);
        }
    }

    public void onFreezeCompleted() {
        if (mPackageMetrics != null && improveInstallFreeze()) {
        if (mPackageMetrics != null) {
            mPackageMetrics.onStepFinished(PackageMetrics.STEP_FREEZE_INSTALL);
        }
    }