fix: deduplicate hidden apps list to prevent duplicate entries#701
Open
mvanhorn wants to merge 172 commits into
Open
fix: deduplicate hidden apps list to prevent duplicate entries#701mvanhorn wants to merge 172 commits into
mvanhorn wants to merge 172 commits into
Conversation
This reverts commit 30834c7.
Race condition between filtering and refreshing apps tanujnotes#417
Adds a (libs.versions.toml) file to centralize dependency management. This improves dependency consistency, reduces maintenance overhead, and simplifies version updates across modules.
…tion Various fixes in the Hungarian translation
(feat) app drawer character list
…ions-catalogue Introduce version catalog for dependency management
target--compile SDK-> 34
(fix) app drawer character list...
Fix fatal crash when renaming apps outside the 'main' user profile
When an app has multiple launchable activities or gets reinstalled after being hidden, the hidden apps list could show duplicates. Track seen package+profile combinations to ensure each package appears at most once.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
When a previously hidden app is reinstalled from Play Store, it can appear twice in the Hidden Apps list. This happens because multiple launchable activities for the same package each get added independently.
Fix
Added a
seenPackagesset ingetAppsList()(Utils.kt) that tracks which package+profile combinations have already been added.Set.add()returnsfalsefor duplicates, so the second activity from the same package is skipped.The fix applies to both hidden and regular app lists for consistency.
Changes
app/src/main/java/app/olauncher/helper/Utils.kt: AddedseenPackagesset and dedup check viaseenPackages.add(packageKey)before adding toappListFixes #467
This contribution was developed with AI assistance (Claude Code).