From b7c81cf066f21e35a00c05e54299c3f7aac9744a Mon Sep 17 00:00:00 2001 From: Pierre Pichet Date: Sat, 19 Dec 2009 21:30:31 +0000 Subject: [PATCH] MDL-20960 testing correctly response 0 as not null line 393 merged from 1.9 --- question/type/multianswer/questiontype.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/question/type/multianswer/questiontype.php b/question/type/multianswer/questiontype.php index 6a9c1027f0..30eab72da2 100644 --- a/question/type/multianswer/questiontype.php +++ b/question/type/multianswer/questiontype.php @@ -390,7 +390,7 @@ class embedded_cloze_qtype extends default_questiontype { // Set up a default chosenanswer so that all non-empty wrong // answers are highlighted red - if (empty($chosenanswer) && !empty($response)) { + if (empty($chosenanswer) && $response != '') { $chosenanswer = new stdClass; $chosenanswer->fraction = 0.0; } -- 2.39.5