Fixed a bug in the Upload class where a PHP error could occur when wildcards were used as the allowed_types.
diff --git a/system/libraries/Upload.php b/system/libraries/Upload.php
index c94e4d4..c18c178 100644
--- a/system/libraries/Upload.php
+++ b/system/libraries/Upload.php
@@ -988,7 +988,7 @@
*/
function _prep_filename($filename)
{
- if (strpos($filename, '.') === FALSE)
+ if (strpos($filename, '.') === FALSE OR $this->allowed_types == '*')
{
return $filename;
}
@@ -1020,4 +1020,4 @@
// END Upload Class
/* End of file Upload.php */
-/* Location: ./system/libraries/Upload.php */
\ No newline at end of file
+/* Location: ./system/libraries/Upload.php */