Browse Source

Use exif_imagetype in Import

Tobias Reich 11 years ago
parent
commit
d0368ea651
1 changed files with 2 additions and 2 deletions
  1. 2 2
      php/modules/Import.php

+ 2 - 2
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