]> git.mjollnir.org Git - moodle.git/commitdiff
Matching qestion type was failing to correctly determine wheterh the student had...
authortjhunt <tjhunt>
Tue, 20 Mar 2007 14:06:56 +0000 (14:06 +0000)
committertjhunt <tjhunt>
Tue, 20 Mar 2007 14:06:56 +0000 (14:06 +0000)
question/type/match/questiontype.php

index 959901d21a1a51f996d12cba6573bb6c3947dddf..43b71c1bcb22f742a526caeae45f54ff05a27a7c 100644 (file)
@@ -368,6 +368,15 @@ class question_match_qtype extends default_questiontype {
         return true;
     }
 
+    function compare_responses($question, $state, $teststate) {
+        foreach ($state->responses as $i=>$sr){
+            if($state->responses[$i] != $teststate->responses[$i]){
+                return false;
+            }
+        }
+        return true;
+    }
+
     // ULPGC ecastro for stats report
     function get_all_responses($question, $state) {
         $answers = array();