Commit 19f5c588 authored by nano's avatar nano

fix error

parent 2d0ab5c3
This diff is collapsed.
......@@ -21,9 +21,9 @@ import config from '../../config';
// }
const checkPackage = async (file) => {
if (['zip', 'gz', 'rar', '7z', 'application/x-gzip'].indexOf(file.mime) === -1) {
throw new Error('Unsupported file type');
if (['application/zip', 'application/gz', 'application/rar', 'application/7z', 'application/x-gzip'].indexOf(file.mime) === -1) {
console.log(file.mime)
throw new Error(`Unsupported file type: ${file.mime}`);
}
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment