Ignore images that can't be processed by the resizer

This commit is contained in:
Luke Towers 2020-09-17 22:53:49 -06:00 committed by GitHub
parent ed06a6f1ac
commit 618e2b58ab
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -612,7 +612,7 @@ class ImageResizer
}
}
if (!$disk || !$path || !$selectedSource) {
if (!$disk || !$path || !$selectedSource || (!in_array(FileHelper::extension($path), ['jpg', 'jpeg', 'png', 'webp', 'gif']))) {
if (is_object($image)) {
$image = get_class($image);
}