Skip to content

Commit

Permalink
Skip handing FileSystem exceptions on file delete
Browse files Browse the repository at this point in the history
  • Loading branch information
Maksold authored Nov 14, 2023
1 parent 01fda08 commit dea9007
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion Command/CatalogAbstract.php
Original file line number Diff line number Diff line change
Expand Up @@ -386,6 +386,12 @@ protected function deleteMediaGalleryPaths(array $mediaGalleryPaths)
*/
protected function deleteFilePaths(array $filePaths)
{
array_map([$this->driverFile, 'deleteFile'], $filePaths);
foreach ($filePaths as $filePath) {
try {
$this->driverFile->deleteFile($filePath);
} catch (\Magento\Framework\Exception\FileSystemException $e) {
// Skip this exceptions
}
}
}
}

0 comments on commit dea9007

Please sign in to comment.