From: danmarsden Date: Mon, 12 Jan 2009 02:27:53 +0000 (+0000) Subject: fixed regression caused by patch for MDL-15105 X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=3b3370febfe9976a9caec1ee160ccbd1f9c8c428;p=moodle.git fixed regression caused by patch for MDL-15105 --- diff --git a/mod/choice/backuplib.php b/mod/choice/backuplib.php index 329d686679..2b1439894d 100644 --- a/mod/choice/backuplib.php +++ b/mod/choice/backuplib.php @@ -123,9 +123,9 @@ $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