mirror of
https://github.com/moodle/moodle.git
synced 2025-01-18 05:58:34 +01:00
MDL-12305 - Don't let the quiz reorder tool put a page break at the start of the quiz. Merged from MOODLE_19_STABLE.
This commit is contained in:
parent
cd6ef0a5bb
commit
3db14d77ec
@ -252,6 +252,10 @@
|
||||
// If ordering info was given, reorder the questions
|
||||
if ($questions) {
|
||||
ksort($questions);
|
||||
// Make sure that the quiz does not start with a page break.
|
||||
while (reset($questions) == '0') {
|
||||
array_shift($questions);
|
||||
}
|
||||
$quiz->questions = implode(",", $questions);
|
||||
// Always have a page break at the end
|
||||
$quiz->questions = $quiz->questions . ',0';
|
||||
|
Loading…
x
Reference in New Issue
Block a user