MDL-14736 Backup/Restore don't halt backup if can't delete temp files - just display notification and save error to log table

This commit is contained in:
danmarsden 2009-03-03 01:18:16 +00:00
parent 6e5e0c9363
commit 9d043b8c6b
2 changed files with 12 additions and 2 deletions

View file

@ -58,7 +58,11 @@ function schedule_backup_cron() {
//Delete old_entries from backup tables
if ($status) {
mtrace(" Deleting old data");
$status = backup_delete_old_data();
if (!backup_delete_old_data()) {;
$errorstr = "An error occurred deleting old backup data";
add_to_backup_log(time(),$preferences->backup_course,$errorstr,'scheduledbackup');
mtrace(" ".$errorstr);
}
}
//Now we get a list of courses in the server