diff --git a/openvidu-testapp/src/app/app.component.ts b/openvidu-testapp/src/app/app.component.ts index 38c3f41e..5c41d234 100644 --- a/openvidu-testapp/src/app/app.component.ts +++ b/openvidu-testapp/src/app/app.component.ts @@ -9,7 +9,7 @@ import { OpenviduParamsService } from './services/openvidu-params.service'; }) export class AppComponent { - openviduURL = 'https://' + window.location.hostname + ':4443/'; + openviduURL = window.location.protocol + '//' + window.location.hostname + ':4443/'; openviduSecret = 'MY_SECRET'; constructor(private router: Router, private openviduParamsService: OpenviduParamsService) { } diff --git a/openvidu-testapp/src/app/components/video/video.component.ts b/openvidu-testapp/src/app/components/video/video.component.ts index e728951d..a9048512 100644 --- a/openvidu-testapp/src/app/components/video/video.component.ts +++ b/openvidu-testapp/src/app/components/video/video.component.ts @@ -230,7 +230,11 @@ export class VideoComponent implements OnInit, OnDestroy { pubUnpubVideo() { const publisher: Publisher = this.streamManager; this.videoMuted = !this.videoMuted; - publisher.publishVideo(!this.videoMuted); + if (this.videoMuted === true) { + publisher.publishVideo(false, true); + } else { + publisher.publishVideo(true); + } this.pubSubVideoIcon = this.videoMuted ? 'videocam_off' : 'videocam'; } diff --git a/openvidu-testapp/src/app/services/openvidu-params.service.ts b/openvidu-testapp/src/app/services/openvidu-params.service.ts index 84582c50..ee0938dc 100644 --- a/openvidu-testapp/src/app/services/openvidu-params.service.ts +++ b/openvidu-testapp/src/app/services/openvidu-params.service.ts @@ -11,7 +11,7 @@ export class OpenviduParamsService { params: OpenviduParams = { - openviduUrl: 'https://' + window.location.hostname + ':4443/', + openviduUrl: window.location.protocol + '//' + window.location.hostname + ':4443/', openviduSecret: 'MY_SECRET' }; diff --git a/openvidu-testapp/src/environments/environment.ts b/openvidu-testapp/src/environments/environment.ts index 5776108d..f1b3425d 100644 --- a/openvidu-testapp/src/environments/environment.ts +++ b/openvidu-testapp/src/environments/environment.ts @@ -5,6 +5,6 @@ export const environment = { production: false, - OPENVIDU_URL: 'https://localhost:4443', + OPENVIDU_URL: 'http://localhost:4443', OPENVIDU_SECRET: 'MY_SECRET' };