Newer Firefox changed the error name when screensharing is not allowed

Update this so the screen sharing help modal dialog opens correctly
This commit is contained in:
Daniel Berteaud 2016-06-02 14:41:21 +02:00
parent a975142f64
commit 9e93ce75d1
1 changed files with 2 additions and 1 deletions

View File

@ -2009,11 +2009,12 @@ function initVroom(room) {
// This error usually means you have denied access (old flag way)
// or you cancelled screen sharing (new extension way)
// or you select no window (in Firefox)
else if (err.name === 'PermissionDeniedError' && $.browser.mozilla){
else if ((err.name === 'PermissionDeniedError' || err.name === 'SecurityError') && $.browser.mozilla){
$('#firefoxShareScreenModal').modal('show');
}
else if (err.name === 'PERMISSION_DENIED' ||
err.name === 'PermissionDeniedError' ||
err.name === 'SecurityError' ||
err.name === 'ConstraintNotSatisfiedError'){
cantShare(localize('SCREEN_SHARING_CANCELLED'));
}