1
0
mirror of https://github.com/devcode-it/openstamanager.git synced 2025-02-16 19:40:44 +01:00

Fix estensioni upload

This commit is contained in:
Thomas Zilio 2018-09-06 11:42:14 +02:00
parent dd7f5e790f
commit d0d2be2a98
2 changed files with 2 additions and 2 deletions

View File

@ -93,7 +93,7 @@ class FileManager implements ManagerInterface
// Anteprime supportate dal browser
$extension = pathinfo($r['original'])['extension'];
$supported_extensions = ['pdf', 'jpg', 'png', 'gif', 'jpeg', 'bmp'];
if (in_array($extension, $supported_extensions)) {
if (in_array(strtolower($extension), $supported_extensions)) {
$result .= "
<div class='hide' id='view-".$r['id']."'>";

View File

@ -147,7 +147,7 @@ class Uploads
*/
protected static function isSupportedType($extension)
{
return in_array($extension, array_keys(self::$allowed_types));
return in_array(strtolower($extension), array_keys(self::$allowed_types));
}
/**