diff --git a/application-client/openvidu-angular/src/app/app.component.ts b/application-client/openvidu-angular/src/app/app.component.ts index a813f894..e5186fa8 100644 --- a/application-client/openvidu-angular/src/app/app.component.ts +++ b/application-client/openvidu-angular/src/app/app.component.ts @@ -111,6 +111,8 @@ export class AppComponent implements OnDestroy { async leaveRoom() { // Leave the room by calling 'disconnect' method over the Room object await this.room?.disconnect(); + + // Reset all variables delete this.room; delete this.localTrack; this.remoteTracksMap.clear();