forked from external-repos/squoosh
I’m an idiot
This commit is contained in:
@@ -113,10 +113,8 @@ async function decodeImage(
|
|||||||
}
|
}
|
||||||
// If none of those work, let’s see if Web Codecs API is available
|
// If none of those work, let’s see if Web Codecs API is available
|
||||||
if (await WebCodecs.isTypeSupported(mimeType)) {
|
if (await WebCodecs.isTypeSupported(mimeType)) {
|
||||||
let result;
|
|
||||||
try {
|
try {
|
||||||
result = await abortable(signal, WebCodecs.decode(blob, mimeType));
|
return await abortable(signal, WebCodecs.decode(blob, mimeType));
|
||||||
return result;
|
|
||||||
} catch (e) {}
|
} catch (e) {}
|
||||||
}
|
}
|
||||||
// Otherwise fall through and try built-in decoding for a laugh.
|
// Otherwise fall through and try built-in decoding for a laugh.
|
||||||
|
|||||||
Reference in New Issue
Block a user