From a2e22fffb3954e22d720bb00d355f6b96f25c6b1 Mon Sep 17 00:00:00 2001 From: prlanzarin <4529051+prlanzarin@users.noreply.github.com> Date: Tue, 30 Apr 2024 13:44:29 -0300 Subject: [PATCH] fix(audio): broken connection stats on Firefox >= 125 WebRTC-based stats generation in the connection status modal is broken on Firefox >= 125. A broken type check coupled with a new partially implemented RTCIceTransport dictionary causes and undefined function call when fetching the selected candidate pair. Since that error is unhandled, collection breaks. Correctly check for the getSelectedCandidatePair method availability in RTCIceTransport so that it skips to pair inference from getStats if necessary. --- .../imports/ui/services/audio-manager/index.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/bigbluebutton-html5/imports/ui/services/audio-manager/index.js b/bigbluebutton-html5/imports/ui/services/audio-manager/index.js index 8c7e653adf..17da058f82 100755 --- a/bigbluebutton-html5/imports/ui/services/audio-manager/index.js +++ b/bigbluebutton-html5/imports/ui/services/audio-manager/index.js @@ -1085,10 +1085,9 @@ class AudioManager { receivers[0] && receivers[0].transport && receivers[0].transport.iceTransport && - receivers[0].transport.iceTransport + typeof receivers[0].transport.iceTransport.getSelectedCandidatePair === 'function' ) { - selectedPair = - receivers[0].transport.iceTransport.getSelectedCandidatePair(); + selectedPair = receivers[0].transport.iceTransport.getSelectedCandidatePair(); } return selectedPair;