Voting count doesn't add up to 100%

Freso - September 24, 2008 - 08:13
Project:Advanced Poll
Version:5.x-1.0-beta6
Component:Code
Category:bug report
Priority:normal
Assigned:Unassigned
Status:won't fix
Description

There's a bug in the algorithm rounding all votes off with no further verification, meaning that you're likely to end up with !=100, e.g.

34% | Kobe Bryant (USA)
29% | LeBron James (USA)
15% | Dwyane Wade (USA)
13% | Pau Gasol (ESP)
8% | Manu Ginobili (ARG)
3% | Luis Scola (ARG)

is 102 in total.

I still haven't figured out what the best approach to solve this would be, but thought I'd toss it out here, in case someone was already familiar with the issue (and perhaps already has a fix).

#1

ChrisKennedy - December 8, 2008 - 05:45
Status:active» won't fix

That's what happens when you round percentages - it is standard and is not a bug. You can use the vote totals to calculate exact percentages if necessary.

 
 

Drupal is a registered trademark of Dries Buytaert.