Skip to content

Jitsi Meet - Secure, Simple and Scalable Video Conferences that you use as a standalone app or embed in your web application.

fix(blur) check model response status and catch errors

Tudor D. Popf69a31d9c610
diff --git a/react/features/stream-effects/blur/index.js b/react/features/stream-effects/blur/index.js
index caa475dedb..57f49fd09f 100644
--- a/react/features/stream-effects/blur/index.js
+++ b/react/features/stream-effects/blur/index.js
@@ -34,6 +34,10 @@ export async function createBlurEffect() {
models['144']
);
+ if (!modelResponse.ok) {
+ throw new Error('Failed to download tflite model!');
+ }
+
const model = await modelResponse.arrayBuffer();
tflite.HEAPU8.set(new Uint8Array(model), modelBufferOffset);