Do not thumbnail xcf files (gimp)

This commit is contained in:
Luc Didry
2016-06-08 21:51:26 +02:00
parent e8eb804d3c
commit fbcc133e47
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -86,7 +86,7 @@ sub startup {
$asset = Mojo::Asset::File->new(path => $path);
}
if (defined $thumb && $im_loaded && $mediatype ne 'image/svg+xml') { # ImageMagick don't work in Debian with svg (for now?)
if (defined $thumb && $im_loaded && $mediatype ne 'image/svg+xml' && $mediatype !~ m#image/(x-)?xcf#) { # ImageMagick don't work in Debian with svg (for now?)
my $im = Image::Magick->new;
$im->BlobToImage($asset->slurp);
+1 -1
View File
@@ -341,7 +341,7 @@ sub add {
my $path = 'files/'.$records[0]->short.'.'.$ext;
my ($width, $height);
if ($im_loaded && $mediatype ne 'image/svg+xml') { # ImageMagick don't work in Debian with svg (for now?)
if ($im_loaded && $mediatype ne 'image/svg+xml' && $mediatype !~ m#image/(x-)?xcf#) { # ImageMagick don't work in Debian with svg (for now?)
my $im = Image::Magick->new;
$im->BlobToImage($upload->slurp);