perhaps you should just do this validation before creating the group at all, instead of having to cleanup when the input is not valid.