Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Correctly detect the mimetype from uploads
Signed-off-by: Joas Schilling <[email protected]>
  • Loading branch information
nickvergessen committed Sep 26, 2019
commit 744b635d5cb885ad2086374eb5791a2c722960bb
2 changes: 1 addition & 1 deletion apps/workflowengine/lib/Check/FileMimeType.php
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ protected function getActualValue() {
$files = $this->request->getUploadedFile('files');
if (isset($files['type'][0])) {
$mimeType = $files['type'][0];
if ($this->mimeType === 'application/octet-stream') {
if ($mimeType === 'application/octet-stream') {
// Maybe not...
$mimeTypeTest = $this->mimeTypeDetector->detectPath($files['name'][0]);
if ($mimeTypeTest !== 'application/octet-stream' && $mimeTypeTest !== false) {
Expand Down