diff --git a/src/util/mimetypes.js b/src/util/mimetypes.js index 7a94e0c..bf7efbc 100644 --- a/src/util/mimetypes.js +++ b/src/util/mimetypes.js @@ -26,6 +26,7 @@ export const ALLOWED_BLOB_MIMETYPES = [ ]; export function getBlobSafeMimeType(mimetype) { + if (typeof mimetype !== 'string') return 'application/octet-stream'; const [type] = mimetype.split(';'); if (!ALLOWED_BLOB_MIMETYPES.includes(type)) { return 'application/octet-stream';