Improved gzip detection
This commit is contained in:
parent
4b0197f2be
commit
1679d866a5
1 changed files with 2 additions and 2 deletions
|
@ -60,8 +60,8 @@ class Pack
|
||||||
throw new DisplayException('The file provided does not appear to be valid.');
|
throw new DisplayException('The file provided does not appear to be valid.');
|
||||||
}
|
}
|
||||||
|
|
||||||
if ($data['file_upload']->getMimeType() !== 'application/gzip') {
|
if (! in_array($data['file_upload']->getMimeType(), ['application/gzip', 'application/x-gzip'])) {
|
||||||
throw new DisplayException('The file provided does not meet the required filetype of application/gzip.');
|
throw new DisplayException('The file provided (' . $data['file_upload']->getMimeType() . ') does not meet the required filetype of application/gzip.');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue