Fixed bug that double-counted previous invoice totals.