Improve error handling in ShutdownHandler by logging warnings for cleanup failures
This commit is contained in:
parent
487eb70b0b
commit
ead20f7924
2 changed files with 3 additions and 3 deletions
|
@ -11,6 +11,7 @@ This update introduces a quality of life improvement
|
|||
|
||||
### Changed
|
||||
- Refactor variable names for consistency and clarity in ShutdownHandler and PackageWriter classes
|
||||
- Improve error handling in ShutdownHandler by logging warnings for cleanup failures
|
||||
|
||||
|
||||
## [2.1.6] - 2024-10-29
|
||||
|
|
|
@ -68,16 +68,15 @@
|
|||
if(count(self::$cleanupPaths) > 0)
|
||||
{
|
||||
$filesystem = new Filesystem();
|
||||
|
||||
foreach(self::$cleanupPaths as $path)
|
||||
{
|
||||
try
|
||||
{
|
||||
//$filesystem->remove($path);
|
||||
$filesystem->remove($path);
|
||||
}
|
||||
catch(Exception $e)
|
||||
{
|
||||
// ignore
|
||||
Console::outWarning('An error occurred while cleaning up temporary path "' . $path . '", ' . $e->getMessage());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue