Skip to content

Jitsi Meet - Secure, Simple and Scalable Video Conferences that you use as a standalone app or embed in your web application.

fix: incompatible effect instance (#10311)

Paweł Domas6a7842ab7e39
diff --git a/conference.js b/conference.js
index 42d74428d7..a6cb846712 100644
--- a/conference.js
+++ b/conference.js
@@ -1015,6 +1015,14 @@ export default {
* dialogs in case of media permissions error.
*/
muteVideo(mute, showUI = true) {
+ if (this.videoSwitchInProgress) {
+ // Turning the camera on while the screen sharing mode is being turned off is causing issues around
+ // the presenter mode handling. It should be okay for the user to click the button again once that's done.
+ console.warn('muteVideo - unable to perform operations while video switch is in progress');
+
+ return;
+ }
+
if (!mute
&& isUserInteractionRequiredForUnmute(APP.store.getState())) {
logger.error('Unmuting video requires user interaction');
@@ -1644,7 +1652,7 @@ export default {
async toggleScreenSharing(toggle = !this._untoggleScreenSharing, options = {}, ignoreDidHaveVideo) {
logger.debug(`toggleScreenSharing: ${toggle}`);
if (this.videoSwitchInProgress) {
- return Promise.reject('Switch in progress.');
+ return Promise.reject(`toggleScreenSharing: ${toggle} aborted - video switch in progress.`);
}
if (!JitsiMeetJS.isDesktopSharingEnabled()) {
return Promise.reject('Cannot toggle screen sharing: not supported.');