When trying to export questions to file, Moodle behaves differently depending on the category to export. For instance, when trying to export the "Default" category AND the Default category is empty, Moodle prompts as follows:
-Questions are being exported to file
-No questions have been added yet
-An error occurred during export processing
When trying to export a named category (different form "Default") AND the category is empty, Moodle prompts as follows:
-Questions are being exported to file
-Cannot write to export file (/var/www/html/mymoodle.tld/moodledata/xx/backupdata/quiz/quiz-testcat-20070914-1002.txt)
Problems:
in the first example, users are prompted for a misleading unknown error: there is no error involved, user has only selected an empty category
In the second example, users are misleaded to think question are exported but something went wrong.
Possible solution:
- prompt the users he is trying to export an empty category for either Default and custom named categories.