소스 검색

Video - multiple video divs for participants - fix

Vijayakrishnan 3 년 전
부모
커밋
fb56debf9b
1개의 변경된 파일9개의 추가작업 그리고 0개의 파일을 삭제
  1. 9 0
      resources/views/app/video/call-minimal.blade.php

+ 9 - 0
resources/views/app/video/call-minimal.blade.php

@@ -139,6 +139,8 @@
             $btnMuteAudio: null,
             $btnUnmuteAudio: null,
 
+            initializing: false,
+
             // methods
             init: function() {
 
@@ -299,6 +301,13 @@
             // init media
             initMedia: function() {
 
+                if(this.initializing) {
+                    console.log('Init already in progress.');
+                    return;
+                }
+
+                this.initializing = true;
+
                 // create client
                 this.mediaServiceClient = AgoraRTC.createClient({mode: 'rtc', codec: 'vp8'});