From e99957f99f8b71b7761c7a3eb884e430a2c9fb3d Mon Sep 17 00:00:00 2001 From: Mario Date: Sun, 16 Apr 2023 11:20:02 +0000 Subject: fix php warning --- include/photo/photo_driver.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'include') diff --git a/include/photo/photo_driver.php b/include/photo/photo_driver.php index 0b691b457..522e638de 100644 --- a/include/photo/photo_driver.php +++ b/include/photo/photo_driver.php @@ -142,7 +142,7 @@ function guess_image_type($filename, $data = '') { if(is_null($type) && strpos($filename, 'http') === 0) { $size = getimagesize($filename); - if (array_key_exists($size['mime'], $types)) + if ($size && array_key_exists($size['mime'], $types)) $type = $size['mime']; } -- cgit v1.2.3