Share code to remove duplicate list of shared classes