]> git.mjollnir.org Git - moodle.git/commitdiff
MDL-16474 Make counts of posts look nicer, and use the scale to show the results...
authormoodler <moodler>
Fri, 12 Sep 2008 07:26:56 +0000 (07:26 +0000)
committermoodler <moodler>
Fri, 12 Sep 2008 07:26:56 +0000 (07:26 +0000)
mod/forum/lib.php

index dbe3afef11f76f7556b9d0672cb1842c7b26d753..07d0a13e2d6d0bfae721f71af72a3ef0610bc735 100644 (file)
@@ -3557,13 +3557,7 @@ function forum_get_ratings_count($postid, $scale, $ratings=NULL) {
         }
     }
 
-    $count = count($ratings);
-    $scalecount = count($scale)-1; //this should give us the last element of the scale aka the max grade with  $scale[$scalecount]
-
-    if ($count > $scale[$scalecount]) { //if the count exceeds the forum scale (i.e. max grade then set the score to the max grade
-        $count = $scale[$scalecount];
-    }
-    return $scale[$count];
+    return count($ratings);
 }
 
 /**