MDL-70901 core: @ no longer masks errors in PHP 8.0

This commit is contained in:
Marina Glancy
2021-02-22 16:18:46 +01:00
parent 2d059d1657
commit b88f1a84bf
3 changed files with 10 additions and 3 deletions
+5 -1
View File
@@ -90,7 +90,11 @@ class file_temp_cleanup_task extends scheduled_task {
} else {
// Return the time modified to the original date only for real files.
if ($iter->isDir() && !$iter->isDot()) {
touch($node, $modifieddateobject[$node]);
try {
@touch($node, $modifieddateobject[$node]);
} catch (\Throwable $t) {
null;
}
}
}
}