diff --git a/Blob.js b/Blob.js index df7dd43..247a2a1 100644 --- a/Blob.js +++ b/Blob.js @@ -358,7 +358,14 @@ ? concatTypedarrays(chunks) : [].concat.apply([], chunks) this.size = this._buffer.length - this.type = opts ? opts.type || '' : '' + + this.type = opts.type || '' + if (/[^\u0020-\u007E]/.test(this.type)) { + this.type = '' + } else { + this.type = this.type.toLowerCase() + } + } Blob.prototype.slice = function (start, end, type) {