diff --git a/Sources/Graphics/Image.php b/Sources/Graphics/Image.php index 0164115ad3d..321ef44a5e2 100644 --- a/Sources/Graphics/Image.php +++ b/Sources/Graphics/Image.php @@ -325,7 +325,11 @@ public function createThumbnail(int $max_width, int $max_height): object|bool } // We don't need to create a thumbnail if one is already embedded. - if (\function_exists('exif_thumbnail') && exif_thumbnail($this->source) !== false) { + // checkForEmbeddedThumb() answered this when the image was loaded, and + // it does so without a warning: exif_thumbnail() emits one for every + // format that cannot carry an embedded thumbnail, so asking it here + // again put a row in the error log for each PNG anyone uploaded. + if ($this->embedded_thumb) { return false; }