You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 16, 2022. It is now read-only.
// Delete old backup_controllers and logs.
$loglifetime = get_config('backup', 'loglifetime');
if (!empty($loglifetime)) { // Value in days.
$loglifetime = $timenow - ($loglifetime * 3600 * 24);
// Delete child records from backup_logs.
$DB->execute("DELETE FROM {backup_logs}
WHERE EXISTS (
SELECT 'x'
FROM {backup_controllers} bc
WHERE bc.backupid = {backup_logs}.backupid
AND bc.timecreated < ?)", array($loglifetime));
// Delete records from backup_controllers.
$DB->execute("DELETE FROM {backup_controllers}
WHERE timecreated < ?", array($loglifetime));
mtrace(" Deleted old backup records");
}
The text was updated successfully, but these errors were encountered:
Taking a second look, we are not using the 'Automated backups' feature on our site, so this is not important to us. But if we were to implement this, it will make this plugin more complete. There were also discussions that we would want to enable 'Automated backups' on our site. So, we may want to revisit this then. I think we can table this for now.
Looks like this is new in Moodle 2.6 and up:
lib/cronlib.php:
The text was updated successfully, but these errors were encountered: