Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions src/utils/webrtc/webrtc.js
Original file line number Diff line number Diff line change
Expand Up @@ -525,8 +525,10 @@ export function initWebRtc(signaling, _callParticipantCollection, _localCallPart
// is received before the "leave call" request ends.
localUserInCall = false

localStateBroadcaster.destroy()
localStateBroadcaster = null
if (localStateBroadcaster) {

@Antreesy Antreesy Aug 28, 2026

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you get a stack trace here from your production setup?

console.trace('beforeLeaveCall', token, reconnect, !!localStateBroadcaster)

I assume this code path is being run twice, so this log could capture it -> so you should see two stacks

localStateBroadcaster.destroy()
localStateBroadcaster = null
}
})
signaling.on('leaveCall', function(token, reconnect) {
// When the MCU is used and there is a connection error the call is
Expand Down
Loading