Skip to content

Commit c124550

Browse files
authored
Merge pull request #5661 from Tyriar/iip
Fix copying array data in IIPHandler
2 parents b2133d9 + 6525a7e commit c124550

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

addons/addon-image/src/IIPHandler.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,8 @@ export class IIPHandler implements IOscHandler, IResetHandler {
105105
return true;
106106
}
107107

108-
const blob = new Blob([new Uint8Array(this._dec.data8)], { type: this._metrics.mime });
108+
// HACK: The types on Blob are too restrictive, this is a Uint8Array so the browser accepts it
109+
const blob = new Blob([this._dec.data8 as Uint8Array<ArrayBuffer>], { type: this._metrics.mime });
109110
this._dec.release();
110111

111112
if (!window.createImageBitmap) {

0 commit comments

Comments
 (0)