fix discord link content-disposition header

This commit is contained in:
Beu 2024-07-11 17:48:25 +02:00
parent 268e7454a9
commit 4d1489ed34

View File

@ -512,7 +512,7 @@ class DirectoryBrowser implements ManialinkPageAnswerListener {
}
if ($filename !== null) {
if ($isUtf8 && strpos($filename, "utf-8''") === 0 && $filename = substr($filename, strlen("utf-8''"))) {
if ($isUtf8 && strpos(strtolower($filename), "utf-8''") === 0 && $filename = substr($filename, strlen("utf-8''"))) {
$filePath = $folderPath . FileUtil::getClearedFileName(rawurldecode($filename));
}
if (substr($filename, 0, 1) === '"' && substr($filename, -1, 1) === '"') {