diff --git a/public/js/Room.js b/public/js/Room.js index f30d58fa..d8d6224b 100644 --- a/public/js/Room.js +++ b/public/js/Room.js @@ -94,6 +94,7 @@ let notify = getNotify(); let peer_geo = null; let peer_info = null; +let isSoundEnabled = true; let isEnumerateAudioDevices = false; let isEnumerateVideoDevices = false; let isAudioAllowed = false; @@ -1222,6 +1223,7 @@ function setVideoButtonsDisabled(disabled) { // #################################################### async function sound(name) { + if (!isSoundEnabled) return; let sound = '../sounds/' + name + '.wav'; let audio = new Audio(sound); try { diff --git a/public/js/RoomClient.js b/public/js/RoomClient.js index 9884222c..bfcb1554 100644 --- a/public/js/RoomClient.js +++ b/public/js/RoomClient.js @@ -1598,6 +1598,7 @@ class RoomClient { // #################################################### async sound(name) { + if (!isSoundEnabled) return; let sound = '../sounds/' + name + '.wav'; let audio = new Audio(sound); try {