diff --git a/src/client/lazy-app/util/index.ts b/src/client/lazy-app/util/index.ts index 7f8917d9..a7e86944 100644 --- a/src/client/lazy-app/util/index.ts +++ b/src/client/lazy-app/util/index.ts @@ -244,9 +244,9 @@ export async function builtinDecode( ): Promise { // If WebCodecs are supported, use that. if (await WebCodecs.isTypeSupported(mimeType)) { - if (signal.aborted) return Promise.reject('Aborted'); + assertSignal(signal); try { - return await WebCodecs.decode(blob, mimeType); + return await abortable(signal, WebCodecs.decode(blob, mimeType)); } catch (e) {} } assertSignal(signal);