mirror of https://github.com/OpenVidu/openvidu.git
ov-components: assign participant name to observable on ready to join
parent
02b594e405
commit
146aeed893
|
@ -138,6 +138,10 @@ export class PreJoinComponent implements OnInit, OnDestroy {
|
||||||
|
|
||||||
// Mark tracks as permanent for avoiding to be removed in ngOnDestroy
|
// Mark tracks as permanent for avoiding to be removed in ngOnDestroy
|
||||||
this.shouldRemoveTracksWhenComponentIsDestroyed = false;
|
this.shouldRemoveTracksWhenComponentIsDestroyed = false;
|
||||||
|
|
||||||
|
// Assign participant name to the observable if it is defined
|
||||||
|
if(this.participantName) this.libService.setParticipantName(this.participantName);
|
||||||
|
|
||||||
this.onReadyToJoin.emit();
|
this.onReadyToJoin.emit();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -549,6 +549,8 @@ export class VideoconferenceComponent implements OnDestroy, AfterViewInit {
|
||||||
this.prejoinSub = this.libService.prejoin$.subscribe((value: boolean) => {
|
this.prejoinSub = this.libService.prejoin$.subscribe((value: boolean) => {
|
||||||
this.showPrejoin = value;
|
this.showPrejoin = value;
|
||||||
if (!this.showPrejoin) {
|
if (!this.showPrejoin) {
|
||||||
|
// Emit token ready if the prejoin page won't be shown
|
||||||
|
|
||||||
// Ensure we have a participant name before proceeding with the join
|
// Ensure we have a participant name before proceeding with the join
|
||||||
this.log.d('Prejoin page is hidden, checking participant name');
|
this.log.d('Prejoin page is hidden, checking participant name');
|
||||||
// Check if we have a participant name already
|
// Check if we have a participant name already
|
||||||
|
|
Loading…
Reference in New Issue