Updated to remove duplicate groupId