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(remotecontrol): Show error on cancel of desktop picker

hristoterezov1498245b9e0b
diff --git a/conference.js b/conference.js
index e23ed7a5cb..102b604adb 100644
--- a/conference.js
+++ b/conference.js
@@ -1183,24 +1183,25 @@ export default {
JitsiMeetJS.analytics.sendEvent(
'conference.sharingDesktop.start');
logger.log('sharing local desktop');
- }).catch((err) => {
+ }).catch(err => {
// close external installation dialog to show the error.
if(externalInstallation)
$.prompt.close();
this.videoSwitchInProgress = false;
- this.toggleScreenSharing(false);
if (err.name === TrackErrors.CHROME_EXTENSION_USER_CANCELED) {
- return;
+ return Promise.reject(err);
}
+ this.toggleScreenSharing(false);
+
logger.error('failed to share local desktop', err);
if (err.name === TrackErrors.FIREFOX_EXTENSION_NEEDED) {
APP.UI.showExtensionRequiredDialog(
config.desktopSharingFirefoxExtensionURL
);
- return;
+ return Promise.reject(err);
}
// Handling: