mirror of
https://github.com/friendica/friendica
synced 2024-11-18 16:23:41 +00:00
On wall_attach, file extension to mimetype matching now breaks the filename at the last . character instead of the first
This commit is contained in:
parent
0c7c1efbd7
commit
5151a82d5e
1 changed files with 1 additions and 1 deletions
|
@ -1088,7 +1088,7 @@ class Mimetype
|
|||
'zsh' => 'text/x-script.zsh'
|
||||
];
|
||||
|
||||
$dot = strpos($filename, '.');
|
||||
$dot = strrpos($filename, '.');
|
||||
if ($dot !== false) {
|
||||
$ext = strtolower(substr($filename, $dot + 1));
|
||||
if (array_key_exists($ext, $mime_types)) {
|
||||
|
|
Loading…
Reference in a new issue