1
0
mirror of https://github.com/moodle/moodle.git synced 2025-04-25 10:26:17 +02:00

Merge branch 'MDL-81494-main' of https://github.com/HuongNV13/moodle

This commit is contained in:
Ilya Tregubov 2024-04-11 09:19:54 +08:00
commit dd364a04a0

@ -365,7 +365,7 @@ class cron {
}
// Only rerun the failed tasks that allow to be re-tried or have the remaining attempts available.
$where .= 'AND (attemptsavailable > 0 OR attemptsavailable IS NULL)';
$where .= ' AND (attemptsavailable > 0 OR attemptsavailable IS NULL)';
$tasks = $DB->get_records_sql("SELECT * from {task_adhoc} WHERE $where", $params);
foreach ($tasks as $t) {
self::run_adhoc_task($t->id);