migrate totalOwnershipUnits and fix errors