MDL-20184 when importing questions from Hot Potatoes files to Moodle question-bank / Quiz module, the readquestions() function wil return "false", to signify an error, if no questions are detected in the import file

This commit is contained in:
gbateson
2009-08-31 02:04:52 +00:00
parent 06d179ba03
commit 3c818366d0
+6 -1
View File
@@ -101,7 +101,12 @@ class qformat_hotpot extends qformat_default {
notice("Unknown quiz type '$xml->quiztype'");
}
} // end switch
return $questions;
if (count($questions)) {
return $questions;
} else {
return false;
}
}
function process_jcloze(&$xml, &$questions) {