浏览代码

fix(ShareDesktopButton): getParticipants reference

master
Hristo Terezov 4 年前
父节点
当前提交
e91df47d1b
共有 1 个文件被更改,包括 1 次插入4 次删除
  1. 1
    4
      react/features/toolbox/components/web/ShareDesktopButton.js

+ 1
- 4
react/features/toolbox/components/web/ShareDesktopButton.js 查看文件

@@ -3,7 +3,6 @@
3 3
 import { translate } from '../../../base/i18n';
4 4
 import { IconShareDesktop } from '../../../base/icons';
5 5
 import JitsiMeetJS from '../../../base/lib-jitsi-meet/_';
6
-import { getParticipants } from '../../../base/participants';
7 6
 import { connect } from '../../../base/redux';
8 7
 import { AbstractButton, type AbstractButtonProps } from '../../../base/toolbox/components';
9 8
 import { getLocalVideoTrack } from '../../../base/tracks';
@@ -123,9 +122,7 @@ const mapStateToProps = state => {
123 122
     if (enableFeaturesBasedOnToken) {
124 123
         // we enable desktop sharing if any participant already have this
125 124
         // feature enabled
126
-        desktopSharingEnabled = getParticipants(state)
127
-            .find(({ features = {} }) =>
128
-                String(features['screen-sharing']) === 'true') !== undefined;
125
+        desktopSharingEnabled = state['features/base/participant'].haveParticipantWithScreenSharingFeature;
129 126
         desktopSharingDisabledTooltipKey = 'dialog.shareYourScreenDisabled';
130 127
     }
131 128
 

正在加载...
取消
保存