Fixes authentication issues.
This commit is contained in:
parent
8d0ee3ded9
commit
4bb555e4b2
|
@ -15676,10 +15676,12 @@ var authenticatedUser = false;
|
|||
|
||||
function connect(jid, password, uiCredentials) {
|
||||
var bosh
|
||||
= uiCredentials.bosh || config.bosh || '/http-bind';
|
||||
= (uiCredentials && uiCredentials.bosh? uiCredentials.bosh : null)
|
||||
|| config.bosh || '/http-bind';
|
||||
connection = new Strophe.Connection(bosh);
|
||||
Moderator.setConnection(connection);
|
||||
|
||||
if(uiCredentials) {
|
||||
var email = uiCredentials.email;
|
||||
var displayName = uiCredentials.displayName;
|
||||
if (email) {
|
||||
|
@ -15690,6 +15692,7 @@ function connect(jid, password, uiCredentials) {
|
|||
if (displayName) {
|
||||
connection.emuc.addDisplayNameToPresence(displayName);
|
||||
}
|
||||
}
|
||||
|
||||
if (connection.disco) {
|
||||
// for chrome, add multistream cap
|
||||
|
|
|
@ -13,10 +13,12 @@ var authenticatedUser = false;
|
|||
|
||||
function connect(jid, password, uiCredentials) {
|
||||
var bosh
|
||||
= uiCredentials.bosh || config.bosh || '/http-bind';
|
||||
= (uiCredentials && uiCredentials.bosh? uiCredentials.bosh : null)
|
||||
|| config.bosh || '/http-bind';
|
||||
connection = new Strophe.Connection(bosh);
|
||||
Moderator.setConnection(connection);
|
||||
|
||||
if(uiCredentials) {
|
||||
var email = uiCredentials.email;
|
||||
var displayName = uiCredentials.displayName;
|
||||
if (email) {
|
||||
|
@ -27,6 +29,7 @@ function connect(jid, password, uiCredentials) {
|
|||
if (displayName) {
|
||||
connection.emuc.addDisplayNameToPresence(displayName);
|
||||
}
|
||||
}
|
||||
|
||||
if (connection.disco) {
|
||||
// for chrome, add multistream cap
|
||||
|
|
Loading…
Reference in New Issue