From ba76cc7544f815e841d5b8915a8d656578ae242a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sa=C3=BAl=20Ibarra=20Corretg=C3=A9?= Date: Mon, 25 Apr 2022 11:14:45 +0200 Subject: [PATCH] fix(virtual-background) don't treat timeout as fatal failure If downloading the model tiemouts, it may succeed in the (near) future, don't just give up. --- react/features/stream-effects/virtual-background/index.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/react/features/stream-effects/virtual-background/index.js b/react/features/stream-effects/virtual-background/index.js index ad70957c5..b45882285 100644 --- a/react/features/stream-effects/virtual-background/index.js +++ b/react/features/stream-effects/virtual-background/index.js @@ -52,14 +52,13 @@ export async function createVirtualBackgroundEffect(virtualBackground: Object, d tflite = await timeout(tfliteTimeout, createTFLiteModule()); } } catch (err) { - isWasmDisabled = true; - if (err?.message === '408') { logger.error('Failed to download tflite model!'); dispatch(showWarningNotification({ titleKey: 'virtualBackground.backgroundEffectError' }, NOTIFICATION_TIMEOUT_TYPE.LONG)); } else { + isWasmDisabled = true; logger.error('Looks like WebAssembly is disabled or not supported on this browser', err); dispatch(showWarningNotification({ titleKey: 'virtualBackground.webAssemblyWarning',