Use exif_imagetype in Import
This commit is contained in:
parent
e3b1a6f477
commit
d0368ea651
@ -36,7 +36,7 @@ class Import extends Module {
|
|||||||
|
|
||||||
foreach ($urls as &$url) {
|
foreach ($urls as &$url) {
|
||||||
|
|
||||||
if (@getimagesize($url)) {
|
if (@exif_imagetype($url)!==false) {
|
||||||
|
|
||||||
$pathinfo = pathinfo($url);
|
$pathinfo = pathinfo($url);
|
||||||
$filename = $pathinfo['filename'] . '.' . $pathinfo['extension'];
|
$filename = $pathinfo['filename'] . '.' . $pathinfo['extension'];
|
||||||
@ -64,7 +64,7 @@ class Import extends Module {
|
|||||||
|
|
||||||
foreach ($files as $file) {
|
foreach ($files as $file) {
|
||||||
|
|
||||||
if (@getimagesize($file)) {
|
if (@exif_imagetype($file)!==false) {
|
||||||
|
|
||||||
# Photo
|
# Photo
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user