It seems like you do not handle an error condition here. This can introduce security issues, and is generally not recommended.
If you suppress an error, we recommend checking for the error condition explicitly:
// For example instead of@mkdir($dir);// Better useif(@mkdir($dir)===false){thrownew\RuntimeException('The directory '.$dir.' could not be created.');}
Loading history...
50
51
$this->createThumbnails($savedFile);
52
53
return $savedFile;
54
}
55
56
/**
57
* Create the necessary thumbnails for the given file
58
* @param $savedFile
59
*/
60
private function createThumbnails($savedFile)
61
{
62
$this->queue->push(function (Job $job) use ($savedFile) {
If you suppress an error, we recommend checking for the error condition explicitly: