diff --git a/openvidu-testapp/src/app/components/video/video.component.ts b/openvidu-testapp/src/app/components/video/video.component.ts index a9048512..e728951d 100644 --- a/openvidu-testapp/src/app/components/video/video.component.ts +++ b/openvidu-testapp/src/app/components/video/video.component.ts @@ -230,11 +230,7 @@ export class VideoComponent implements OnInit, OnDestroy { pubUnpubVideo() { const publisher: Publisher = this.streamManager; this.videoMuted = !this.videoMuted; - if (this.videoMuted === true) { - publisher.publishVideo(false, true); - } else { - publisher.publishVideo(true); - } + publisher.publishVideo(!this.videoMuted); this.pubSubVideoIcon = this.videoMuted ? 'videocam_off' : 'videocam'; }