[svn r17291] minor - style changes - eliminated error : division by zero - (partial FS#3249)

skala
Isaac Flores 16 years ago
parent 848b9b7544
commit 3e62e8c1a9
  1. 3
      main/gradebook/lib/scoredisplay.class.php

@ -263,7 +263,8 @@ class ScoreDisplay
}
private function display_as_percent ($score) {
return round(($score[0] / $score[1]) * 100) . ' %';
$score_denom=($score[1]==0) ? 1 : $score[1];
return round(($score[0] / $score_denom) * 100) . ' %';
}
private function display_as_div ($score) {

Loading…
Cancel
Save