From 7f2c3f81f8772c0d088ef448938d556eaeb8cf14 Mon Sep 17 00:00:00 2001 From: Skyler Murray Date: Fri, 13 Sep 2024 17:03:30 -0700 Subject: [PATCH] fix(bug): _setPrimary should set _primary before _emit is sent Fixed a subtle bug where we set _primary after sending the event so the event and the call list didn't have a primary call set. --- src/lwpCall.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/lwpCall.js b/src/lwpCall.js index 37db29f..5f614d1 100644 --- a/src/lwpCall.js +++ b/src/lwpCall.js @@ -739,10 +739,10 @@ export default class lwpCall { this.unhold(); } - this._emit("promoted", this); - this._primary = true; + this._emit("promoted", this); + this._connectStreams(); }