fix disconnect of js once event

Signed-off-by: Timo K <toger5@hotmail.de>
This commit is contained in:
Timo K
2024-04-16 16:14:58 +02:00
parent ce2ce4b099
commit 5c1205cb9d

View File

@@ -135,7 +135,7 @@ async function connectAndPublish(
const tracker = PosthogAnalytics.instance.eventCallConnectDuration;
// Track call connect duration
tracker.cacheConnectStart();
livekitRoom.once(RoomEvent.SignalConnected, () => tracker.cacheWsConnect());
livekitRoom.once(RoomEvent.SignalConnected, tracker.cacheWsConnect);
await livekitRoom!.connect(sfuConfig!.url, sfuConfig!.jwt, {
// Due to stability issues on Firefox we are testing the effect of different