From 3defad20ccdf887efbab73427db26c701d68f7bf Mon Sep 17 00:00:00 2001 From: Carlos Santos <4a.santos@gmail.com> Date: Fri, 7 Mar 2025 13:04:06 +0100 Subject: [PATCH] ov-components: emit room created event after participant connection --- .../src/lib/components/session/session.component.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/openvidu-components-angular/projects/openvidu-components-angular/src/lib/components/session/session.component.ts b/openvidu-components-angular/projects/openvidu-components-angular/src/lib/components/session/session.component.ts index ffcc7c68..055f87e1 100644 --- a/openvidu-components-angular/projects/openvidu-components-angular/src/lib/components/session/session.component.ts +++ b/openvidu-components-angular/projects/openvidu-components-angular/src/lib/components/session/session.component.ts @@ -185,7 +185,6 @@ export class SessionComponent implements OnInit, OnDestroy { async ngOnInit() { this.room = this.openviduService.getRoom(); - this.onRoomCreated.emit(this.room); // this.subscribeToCaptionLanguage(); this.subcribeToActiveSpeakersChanged(); @@ -208,6 +207,8 @@ export class SessionComponent implements OnInit, OnDestroy { } try { await this.participantService.connect(); + // Send room created after participant connect for avoiding to send incomplete room payload + this.onRoomCreated.emit(this.room); this.cd.markForCheck(); this.loading = false; this.onParticipantCreated.emit(this.participantService.getLocalParticipant());