added method to remove metaclasses.