fix updating vote calculation