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

* add option for disabling join/leave sounds

* document disableJoinLeaveSounds and add it to whitelist
This commit is contained in:
adam j hartz
2021-03-22 12:28:34 -04:00
committed by GitHub
parent 6175a5cad5
commit 67beafc9af
3 changed files with 11 additions and 1 deletions

View File

@@ -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.