Skip to content
Browse files

corrected display of best grade on "index.php" when maximum grade for…

… the HotPot is not 100
  • Loading branch information...
1 parent 1387c87 commit a8fdaa5c38e4194cb47eba52778fb8178b393f4d gbateson committed Oct 2, 2006
Showing with 3 additions and 1 deletion.
  1. +3 −1 mod/hotpot/index.php
View
4 mod/hotpot/index.php
@@ -359,7 +359,9 @@
// get best score
if (is_numeric($totals[$hotpot->id]->maxscore)) {
- $bestscore = $totals[$hotpot->id]->maxscore." / $hotpot->grade";
+ $weighting = $hotpot->grade / 100;
+ $precision = hotpot_get_precision($hotpot);
+ $bestscore = round($totals[$hotpot->id]->maxscore * $weighting, $precision)." / $hotpot->grade";
} else {
$bestscore = " ";
}

0 comments on commit a8fdaa5

Please sign in to comment.
Something went wrong with that request. Please try again.