From 83da4448fac29d3ef6d95f9c7e041c6cbe904f2a Mon Sep 17 00:00:00 2001
From: Ramon Souza <contato@ramonsouza.com>
Date: Thu, 10 Jun 2021 09:14:51 -0300
Subject: [PATCH] fix attendee auto join audio locked

---
 .../imports/ui/components/audio/audio-modal/component.jsx    | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/bigbluebutton-html5/imports/ui/components/audio/audio-modal/component.jsx b/bigbluebutton-html5/imports/ui/components/audio/audio-modal/component.jsx
index 0f336dcd6f..d6155fcb0b 100755
--- a/bigbluebutton-html5/imports/ui/components/audio/audio-modal/component.jsx
+++ b/bigbluebutton-html5/imports/ui/components/audio/audio-modal/component.jsx
@@ -169,10 +169,9 @@ class AudioModal extends Component {
     } = this.props;
 
     if (!isUsingAudio) {
-      if (forceListenOnlyAttendee) return this.handleJoinListenOnly();
+      if (forceListenOnlyAttendee || audioLocked) return this.handleJoinListenOnly();
 
-      if ((joinFullAudioImmediately && !listenOnlyMode)
-        || audioLocked) return this.handleJoinMicrophone();
+      if (joinFullAudioImmediately && !listenOnlyMode) return this.handleJoinMicrophone();
     }
   }
 
-- 
GitLab