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

Commit 94387b55 authored by Fyodor Kupolov's avatar Fyodor Kupolov Committed by android-build-merger
Browse files

Cache package names after reboot

am: 773e9974

Change-Id: I556f33c4664d37de4a64ffb26b99f7a083edf15b
parents 6bcbe9a7 773e9974
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -130,6 +130,10 @@ class PreloadAppsInstaller {
                    // Install on user 0 so that the package is cached when demo user is re-created
                    installExistingPackage(basePackageName, UserHandle.USER_SYSTEM, counter);
                } else if (returnCode == PackageManager.INSTALL_FAILED_ALREADY_EXISTS) {
                    // This can only happen in first session after a reboot
                    if (!mApkToPackageMap.containsKey(apkName)) {
                        mApkToPackageMap.put(apkName, basePackageName);
                    }
                    installExistingPackage(basePackageName, userId, counter);
                }
            }