FIX: Upload valid file check

This commit is contained in:
2021-12-23 00:08:28 -03:00
parent 1a0c83fb2b
commit 66882d9f85

View File

@ -42,7 +42,7 @@ class FileHandler {
if ($file->getError() !== UPLOAD_ERR_OK) {
return false;
}
if (!in_array($file->getClientMediaType(), array_keys($this->valid_types))) {
if (!in_array($file->getClientMediaType(), $this->valid_types)) {
return false;
}
if ($new_name === null) {