Quellcode durchsuchen

fix(remote-video): update remote video menu if it exists

In RemoteVideo, creation of the RemoteVideoMenu (popover) is
skipped if in filmstrip only mode. However, updateRemoteVideoMenu
is called by other components, and that tries to access popover
and will error.

Add a defensive check for now as filmstrip is being rewritten
for react.
j8
Leonard Kim vor 8 Jahren
Ursprung
Commit
73dd7440d0
1 geänderte Dateien mit 4 neuen und 1 gelöschten Zeilen
  1. 4
    1
      modules/UI/videolayout/RemoteVideo.js

+ 4
- 1
modules/UI/videolayout/RemoteVideo.js Datei anzeigen

@@ -436,9 +436,12 @@ RemoteVideo.prototype._setAudioVolume = function (scale, newVal) {
436 436
  * @param force to work even if popover is not visible
437 437
  */
438 438
 RemoteVideo.prototype.updateRemoteVideoMenu = function (isMuted, force) {
439
-
440 439
     this.isAudioMuted = isMuted;
441 440
 
441
+    if (!this.popover) {
442
+        return;
443
+    }
444
+
442 445
     // generate content, translate it and add it to document only if
443 446
     // popover is visible or we force to do so.
444 447
     if(this.popover.popoverShown || force) {

Laden…
Abbrechen
Speichern