From e4b522e9419db57d2038fd83653497b81e743df0 Mon Sep 17 00:00:00 2001
From: Chad Pilkey <capilkey@gmail.com>
Date: Mon, 9 Mar 2020 17:52:49 +0000
Subject: [PATCH] fix client crash race condition with presentation pods

---
 .../actions-bar/actions-dropdown/component.jsx         | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/bigbluebutton-html5/imports/ui/components/actions-bar/actions-dropdown/component.jsx b/bigbluebutton-html5/imports/ui/components/actions-bar/actions-dropdown/component.jsx
index 6e43bc0c2a..39abcaaa77 100755
--- a/bigbluebutton-html5/imports/ui/components/actions-bar/actions-dropdown/component.jsx
+++ b/bigbluebutton-html5/imports/ui/components/actions-bar/actions-dropdown/component.jsx
@@ -186,11 +186,11 @@ class ActionsDropdown extends PureComponent {
       podIds,
     } = this.props;
 
-    let podId = null;
-    if (podIds) {
-      const defaultPodId = podIds[0].podId;
-      podId = podIds.length > 0 ? defaultPodId : null;
-    }
+    if (!podIds || podIds.length < 1) return [];
+
+    // We still have code for other pods from the Flash client. This intentionally only cares
+    // about the first one because it's the default.
+    const { podId } = podIds[0];
 
     const presentationItemElements = presentations.map((p) => {
       const itemStyles = {};
-- 
GitLab