Fixed: Get original image through storage
This commit is contained in:
parent
ea55bfd427
commit
c8ee7f1514
|
@ -27,7 +27,7 @@ class ImageResizer
|
||||||
public function generate(string $file): void
|
public function generate(string $file): void
|
||||||
{
|
{
|
||||||
$this->source = app(FileObserver::class)->normalizePath($file);
|
$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;
|
return;
|
||||||
}
|
}
|
||||||
$this->copyOriginalImage();
|
$this->copyOriginalImage();
|
||||||
|
|
Loading…
Reference in New Issue