mirror of
https://github.com/moodle/moodle.git
synced 2025-08-04 16:36:37 +02:00
MDLSITE-320 some debug code for digest times in forum cron; merged from MOODLE_19_STABLE
This commit is contained in:
parent
7d44b1a425
commit
291b184bc4
1 changed files with 3 additions and 0 deletions
|
@ -479,6 +479,9 @@ function forum_cron() {
|
||||||
$timenow = time();
|
$timenow = time();
|
||||||
$digesttime = usergetmidnight($timenow, $sitetimezone) + ($CFG->digestmailtime * 3600);
|
$digesttime = usergetmidnight($timenow, $sitetimezone) + ($CFG->digestmailtime * 3600);
|
||||||
|
|
||||||
|
// some debug code for 2digests per day problem
|
||||||
|
mtrace(' (Expected digest time today: '.$digesttime.' admin user zone:'.userdate($digesttime).' site zone:'.userdate($digesttime, '', $sitetimezone).')');
|
||||||
|
|
||||||
// Delete any really old ones (normally there shouldn't be any)
|
// Delete any really old ones (normally there shouldn't be any)
|
||||||
$weekago = $timenow - (7 * 24 * 3600);
|
$weekago = $timenow - (7 * 24 * 3600);
|
||||||
delete_records_select('forum_queue', "timemodified < $weekago");
|
delete_records_select('forum_queue', "timemodified < $weekago");
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue