mirror of
https://github.com/moodle/moodle.git
synced 2025-04-13 12:32:08 +02:00
MDL-45455 quiz cron must rollback transaction on error.
This commit is contained in:
parent
a929fd50f9
commit
6f988b712d
@ -84,6 +84,9 @@ class mod_quiz_overdue_attempt_updater {
|
||||
mtrace("Error while processing attempt {$attempt->id} at {$attempt->quiz} quiz:");
|
||||
mtrace($e->getMessage());
|
||||
mtrace($e->getTraceAsString());
|
||||
// Close down any currently open transactions, otherwise one error
|
||||
// will stop following DB changes from being committed.
|
||||
$DB->force_transaction_rollback();
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user