Skip to content

Commit

Permalink
Fix key calculation (#610)
Browse files Browse the repository at this point in the history
  • Loading branch information
CartierPierre authored Feb 20, 2025
1 parent 27c998d commit 5a49aee
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion questionnaire.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -3924,7 +3924,7 @@ public function response_analysis($rid, $resps, $compare, $isgroupmember, $allre
// Just in case a question pertaining to a section has been deleted or made not required
// after being included in scorecalculation.
if (isset($qscore[$qid])) {
$key = ($key == 0) ? 1 : $key;
$key = empty($key) ? 1 : $key;
$score[$section] += round($qscore[$qid] * $key);
$maxscore[$section] += round($qmax[$qid] * $key);
if ($compare || $allresponses) {
Expand Down

0 comments on commit 5a49aee

Please sign in to comment.