Skip to content

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

add option for disabling join/leave sounds (#8596)

adam j hartz67beafc9affa
diff --git a/config.js b/config.js
index fe0aea18be..f92b88d13c 100644
--- a/config.js
+++ b/config.js
@@ -563,6 +563,10 @@ var config = {
// Decides whether the start/stop recording audio notifications should play on record.
// disableRecordAudioNotification: false,
+ // Disables the sounds that play when other participants join or leave the
+ // conference (if set to true, these sounds will not be played).
+ // disableJoinLeaveSounds: false,
+
// Information for the chrome extension banner
// chromeExtensionBanner: {
// // The chrome extension to be installed address
diff --git a/react/features/base/config/configWhitelist.js b/react/features/base/config/configWhitelist.js
index 1eae5fee8e..3f6d2618a6 100644
--- a/react/features/base/config/configWhitelist.js
+++ b/react/features/base/config/configWhitelist.js
@@ -84,6 +84,7 @@ export default [
'disableH264',
'disableHPF',
'disableInviteFunctions',
+ 'disableJoinLeaveSounds',
'disableLocalVideoFlip',
'disableNS',
'disableProfile',
diff --git a/react/features/base/participants/middleware.js b/react/features/base/participants/middleware.js
index ff038c64e9..91448cd750 100644
--- a/react/features/base/participants/middleware.js
+++ b/react/features/base/participants/middleware.js
@@ -339,7 +339,12 @@ function _localParticipantLeft({ dispatch }, next, action) {
*/
function _maybePlaySounds({ getState, dispatch }, action) {
const state = getState();
- const { startAudioMuted } = state['features/base/config'];
+ const { startAudioMuted, disableJoinLeaveSounds } = state['features/base/config'];
+
+ // If we have join/leave sounds disabled, don't play anything.
+ if (disableJoinLeaveSounds) {
+ return;
+ }
// We're not playing sounds for local participant
// nor when the user is joining past the "startAudioMuted" limit.