fixed bugs regarding groups after database update