From d0368ea651867cf3bad88b512bd59f387709911e Mon Sep 17 00:00:00 2001 From: Tobias Reich Date: Sat, 26 Apr 2014 19:40:34 +0200 Subject: [PATCH] Use exif_imagetype in Import --- php/modules/Import.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/php/modules/Import.php b/php/modules/Import.php index 0fb5d04..b72168f 100644 --- a/php/modules/Import.php +++ b/php/modules/Import.php @@ -36,7 +36,7 @@ class Import extends Module { foreach ($urls as &$url) { - if (@getimagesize($url)) { + if (@exif_imagetype($url)!==false) { $pathinfo = pathinfo($url); $filename = $pathinfo['filename'] . '.' . $pathinfo['extension']; @@ -64,7 +64,7 @@ class Import extends Module { foreach ($files as $file) { - if (@getimagesize($file)) { + if (@exif_imagetype($file)!==false) { # Photo