related to #1657 better condition for svg verification

This commit is contained in:
Matthieu Leproux
2022-05-17 16:37:11 +02:00
parent 61c26661b5
commit a6e695a026
+3 -3
View File
@@ -57,11 +57,11 @@ final class SrcImage
$this->flags |= self::IS_MIMETYPE;
if ( ($size=@getimagesize(PHPWG_ROOT_PATH.$this->rel_path)) === false)
{
$extTab = explode('.',$infos['path']);
if (strtoupper(end($extTab)) == 'SVG')
if ('svg' == $ext)
{
$this->rel_path = $infos['path'];
} else
}
else
{
$this->rel_path = 'themes/default/icon/mimetypes/unknown.png';
}