Removes duplicate apps and fixes apps duplicating during installs.