Fix for OffByOne/DivByZero conflict in votes totals
More refactoring for consistency