remove un-necessary intermediate collections when generating the objectClass