Fix errors with sums.