From 5a1d200098caa1f8226fc1021340500d6b441f64 Mon Sep 17 00:00:00 2001 From: isymchych Date: Tue, 16 Feb 2016 17:42:28 +0200 Subject: [PATCH] fix authentication dialog --- conference.js | 3 ++- modules/UI/authentication/AuthHandler.js | 12 ++++++++---- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/conference.js b/conference.js index efa4d0b80..7e5ed08e6 100644 --- a/conference.js +++ b/conference.js @@ -193,7 +193,8 @@ class ConferenceConnector { }, 5000); // notify user that auth is required - AuthHandler.requireAuth(APP.conference.roomName); + + AuthHandler.requireAuth(room, roomLocker.password); break; case ConferenceErrors.RESERVATION_ERROR: diff --git a/modules/UI/authentication/AuthHandler.js b/modules/UI/authentication/AuthHandler.js index 8521b65d1..3c71ce64f 100644 --- a/modules/UI/authentication/AuthHandler.js +++ b/modules/UI/authentication/AuthHandler.js @@ -54,7 +54,9 @@ function doXmppAuth (room, lockPassword) { // 4. reallocate focus in current room openConnection({id, password}).then(function (connection) { // open room - let newRoom = connection.initJitsiConference(room.getName()); + let newRoom = connection.initJitsiConference( + room.getName(), APP.conference._getConferenceOptions() + ); loginDialog.displayConnectionStatus( APP.translation.translateString('connection.FETCH_SESSION_ID') @@ -105,20 +107,22 @@ function authenticate (room, lockPassword) { if (room.isExternalAuthEnabled()) { doExternalAuth(room, lockPassword); } else { - doXmppAuth(); + doXmppAuth(room, lockPassword); } } /** * Notify user that authentication is required to create the conference. + * @param {JitsiConference} room + * @param {string} [lockPassword] password to use if the conference is locked */ -function requireAuth(roomName) { +function requireAuth(room, lockPassword) { if (authRequiredDialog) { return; } authRequiredDialog = LoginDialog.showAuthRequiredDialog( - roomName, authenticate + room.getName(), authenticate.bind(null, room, lockPassword) ); }