Fix controllo sui permessi all'aggiornamento

This commit is contained in:
MatteoPistorello 2021-12-13 16:24:40 +01:00
parent 04c00952bf
commit 469e0acc16
2 changed files with 8 additions and 3 deletions

View File

@ -130,7 +130,9 @@ function copyr($source, $destination, $ignores = [])
// Filesystem Symfony
$fs = new SymfonyFilesystem();
$fs->chmod($destination, 0777, 0000, true);
try {
$fs->chmod($destination, 0777, 0000, true);
} catch (\Exception $e) {}
foreach ($files as $file) {
$filename = rtrim($destination, DIRECTORY_SEPARATOR).DIRECTORY_SEPARATOR.$file->getRelativePathname();

View File

@ -212,8 +212,11 @@ class Update
// Correzione permessi per le cartelle backup e files
$fs = new SymfonyFilesystem();
$fs->chmod('backup', 0777, 0000, true);
$fs->chmod('files', 0777, 0000, true);
try {
$fs->chmod('backup', 0777, 0000, true);
$fs->chmod('files', 0777, 0000, true);
} catch (\Exception $e) {}
return true;
}