Fixed: Delete processed ResizeJob
This commit is contained in:
parent
d8dacc6546
commit
2ad9b01044
|
@ -11,13 +11,9 @@ class ResizeJob
|
|||
|
||||
public function fire($job, $params)
|
||||
{
|
||||
try {
|
||||
list($file) = $params;
|
||||
app(ImageResizer::class)->generate(new MediaPath($file), $params['update'] ?? false);
|
||||
} catch (Throwable $e) {
|
||||
Log::error('Resizing of image failed. Message: "'.$e->getMessage().'" in file "'.$e->getFile().'" on line '.$e->getLine());
|
||||
throw $e;
|
||||
}
|
||||
list($file) = $params;
|
||||
app(ImageResizer::class)->generate(new MediaPath($file), $params['update'] ?? false);
|
||||
$job->delete();
|
||||
}
|
||||
|
||||
public function failed($data, Throwable $e)
|
||||
|
|
Loading…
Reference in New Issue