From e2a664d43c12c4cadd9a897cd7f13e90c7880c50 Mon Sep 17 00:00:00 2001 From: Stephan Kergomard Date: Tue, 14 Nov 2023 17:42:17 +0100 Subject: [PATCH] Test: Fix String of Float Instead of Int as Key See: https://mantis.ilias.de/view.php?id=38773 --- Modules/TestQuestionPool/classes/class.assTextSubsetGUI.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Modules/TestQuestionPool/classes/class.assTextSubsetGUI.php b/Modules/TestQuestionPool/classes/class.assTextSubsetGUI.php index 13248990d047..4930e280da33 100755 --- a/Modules/TestQuestionPool/classes/class.assTextSubsetGUI.php +++ b/Modules/TestQuestionPool/classes/class.assTextSubsetGUI.php @@ -169,7 +169,7 @@ public function getSolutionOutput( foreach ($this->object->answers as $answer) { $points_string_for_key = (string) $answer->getPoints(); if ($answer->getPoints() > 0) { - if (!array_key_exists($answer->getPoints(), $rank)) { + if (!array_key_exists($points_string_for_key, $rank)) { $rank[$points_string_for_key] = array(); } array_push($rank[$points_string_for_key], $answer->getAnswertext());