]> git.mjollnir.org Git - moodle.git/commitdiff
fixed regression caused by patch for MDL-15105
authordanmarsden <danmarsden>
Mon, 12 Jan 2009 02:27:53 +0000 (02:27 +0000)
committerdanmarsden <danmarsden>
Mon, 12 Jan 2009 02:27:53 +0000 (02:27 +0000)
mod/choice/backuplib.php

index 329d686679732d032bc80c12011ab4f2a97687b5..2b1439894dec942b13b20dc4e3380ec8cade62cb 100644 (file)
 
         $status = true;
 
-        $choice_answers = $DB->get_records("choice_options", array("choiceid" => $choice),"id");
+        $choice_options = $DB->get_records("choice_options", array("choiceid" => $choice),"id");
         //If there is options
-        if ($choice_options) {
+        if (!empty($choice_options)) {
             //Write start tag
             $status =fwrite ($bf,start_tag("OPTIONS",4,true));
             //Iterate over each answer