Fixed: Get original image through storage

This commit is contained in:
philipp lang 2021-09-06 19:14:01 +02:00
parent ea55bfd427
commit c8ee7f1514
1 changed files with 1 additions and 1 deletions

View File

@ -27,7 +27,7 @@ class ImageResizer
public function generate(string $file): void
{
$this->source = app(FileObserver::class)->normalizePath($file);
if ($this->media->findFiles($this->source)[0]->getFileType() !== 'image') {
if (Storage::mimeType(app(FileObserver::class)->fullMediaPath($file)) !== 'image/jpeg') {
return;
}
$this->copyOriginalImage();