From eac7a2afc4264b77cee19e3349ea85a69e29327e Mon Sep 17 00:00:00 2001 From: Juliusz Chroboczek Date: Fri, 4 Sep 2020 01:17:06 +0200 Subject: [PATCH] Display a notification when local stream fails. We used to silently fail when there was a problem with camera permissions. Display a notification. --- static/sfu.js | 2 ++ 1 file changed, 2 insertions(+) diff --git a/static/sfu.js b/static/sfu.js index 29ed2d1..3086213 100644 --- a/static/sfu.js +++ b/static/sfu.js @@ -378,6 +378,7 @@ async function addLocalMedia(id) { stream = await navigator.mediaDevices.getUserMedia(constraints); } catch(e) { console.error(e); + displayError(e); if(old) delUpMedia(old); return; @@ -411,6 +412,7 @@ async function addShareMedia(setup) { stream = await navigator.mediaDevices.getDisplayMedia({}); } catch(e) { console.error(e); + displayError(e); return; }