Skip to content

Commit

Permalink
Fix key calculation
Browse files Browse the repository at this point in the history
  • Loading branch information
CartierPierre authored Oct 7, 2024
1 parent f2ffa46 commit 2e7fa17
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 @@ -3923,7 +3923,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 2e7fa17

Please sign in to comment.