diff --git a/app/Models/Media.php b/app/Models/Media.php index bc7fe75..a18a21d 100644 --- a/app/Models/Media.php +++ b/app/Models/Media.php @@ -694,11 +694,13 @@ class Media extends Model } $im = $im->deconstructImages(); } + $im->setImageFormat(MediaExtension::gif); $storage->put( $this->preview_relative_path, $im->getImagesBlob() ); } else { + $im->setImageFormat(\pathinfo($this->preview_relative_path, \PATHINFO_EXTENSION)); if ($this->largeur >= $format->largeur || $this->hauteur >= $format->hauteur || $this->largeur == "") { $im->thumbnailImage($format->largeur, $format->hauteur, true); }