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

Commit 6f317426 authored by Christopher Tate's avatar Christopher Tate
Browse files

Don't issue a deletion for the global metadata backup

We were accidentally submitting a deletion for the global metadata key in the
PM backup handling (it was falling into the usual "here's a package that we said
we'd backed up last time, but now it's no longer on device" code).  Don't do
that any more, i.e. actually keep the global metadata key in the backup set.
Oops.
parent bbd63cb2
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -120,7 +120,10 @@ public class PackageManagerBackupAgent extends BackupAgent {
            // write its signature block to the output, keyed on the package name.
            for (PackageInfo pkg : mAllPackages) {
                String packName = pkg.packageName;
                if (!existing.contains(packName)) {
                if (packName.equals(GLOBAL_METADATA_KEY)) {
                    // We've already handled the metadata key; skip it here
                    continue;
                } else if (!existing.contains(packName)) {
                    // We haven't stored this app's signatures yet, so we do that now
                    try {
                        PackageInfo info = mPackageManager.getPackageInfo(packName,