Skip to content

Commit

Permalink
Merge pull request #781 from grote/exclude-us
Browse files Browse the repository at this point in the history
Exclude ourselves from backup status
  • Loading branch information
grote authored Oct 16, 2024
2 parents f5c2f0b + 321c049 commit 1299008
Showing 1 changed file with 5 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,11 @@ internal class AppListRetriever(
val locale = Locale.getDefault()
return (userApps + packageService.launchableSystemApps.mapNotNull {
val packageName = it.activityInfo.packageName
if (packageName in userPackages) return@mapNotNull null
if (packageName in userPackages || packageName == context.packageName) {
// don't re-add user packages again,
// also on some ROMs we are a launchableSystemApp, so we need to exclude ourselves
return@mapNotNull null
}
val metadata = metadataManager.getPackageMetadata(packageName)
AppStatus(
packageName = packageName,
Expand Down

0 comments on commit 1299008

Please sign in to comment.