diff options
author | Tim Almdal <tnalmdal@shaw.ca> | 2009-02-23 05:59:13 +0000 |
---|---|---|
committer | Tim Almdal <tnalmdal@shaw.ca> | 2009-02-23 05:59:13 +0000 |
commit | 05308a94b11fb6f51b7b0338ea67793da0d46501 (patch) | |
tree | f01e45209265e59c342fed1de30e77714bfbfa22 | |
parent | 51591c9669aa536a1434f0bb21f96508ee37ae09 (diff) |
Use IMAGETYPE_xxx to filter file types
-rw-r--r-- | modules/local_import/controllers/local_import.php | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/local_import/controllers/local_import.php b/modules/local_import/controllers/local_import.php index 3367bf7d..7302aae5 100644 --- a/modules/local_import/controllers/local_import.php +++ b/modules/local_import/controllers/local_import.php @@ -92,7 +92,7 @@ class Local_Import_Controller extends Controller { $extension = strtolower(substr(strrchr($file, '.'), 1)); // Make sure the file is readable if (is_readable($full_path) && - in_array($extension, array("gif", "jpg", "jpeg", "png", "flv"))) { + in_array($extension, array(IMAGETYPE_GIF, IMAGETYPE_JPEG, IMAGETYPE_PNG, "flv"))) { $file_list[$file] = array("path" => $full_path); } } |