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

Commit 52fe0c39 authored by Ivan Chiang's avatar Ivan Chiang
Browse files

[PM] Only send Intent#ACTION_UID_REMOVED when removing data

If DELETE_KEEP_DATA is true, don't send Intent#ACTION_UID_REMOVED.

Bug: 336452601
Test: Manual, no Intent#ACTION_UID_REMOVED broadcast
Change-Id: I8719ab27ac476223a11454ae31590b5959b86fef
parent d725ff4f
Loading
Loading
Loading
Loading
+5 −1
Original line number Diff line number Diff line
@@ -513,7 +513,11 @@ final class DeletePackageHelper {
                // Legacy behavior to report appId as UID here.
                // The final broadcasts will contain a per-user UID.
                outInfo.mUid = ps.getAppId();
                // Only send Intent.ACTION_UID_REMOVED when flag & DELETE_KEEP_DATA is 0
                // i.e. the mDataRemoved is true
                if (outInfo.mDataRemoved) {
                    outInfo.mIsAppIdRemoved = true;
                }
                mPm.scheduleWritePackageRestrictions(user);
                return;
            }