Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
converse.js
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
converse.js
Commits
ea207ad6
Commit
ea207ad6
authored
May 11, 2017
by
JC Brand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Don't override `credentials_url` password with connection password
Causes login failure when one-time tokens are used.
parent
7eecd6b1
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
5 deletions
+4
-5
src/converse-core.js
src/converse-core.js
+4
-5
No files found.
src/converse-core.js
View file @
ea207ad6
...
...
@@ -1973,10 +1973,9 @@
this
.
autoLogin
=
function
(
credentials
)
{
if
(
credentials
)
{
// If passed in, the
n they come from credentials_url, so we
// s
et them on the _
converse object.
// If passed in, the
credentials come from credentials_url,
// s
o we set them on the
converse object.
this
.
jid
=
credentials
.
jid
;
this
.
password
=
credentials
.
password
;
}
if
(
this
.
authentication
===
_converse
.
ANONYMOUS
)
{
if
(
!
this
.
jid
)
{
...
...
@@ -1988,9 +1987,9 @@
this
.
connection
.
reset
();
this
.
connection
.
connect
(
this
.
jid
.
toLowerCase
(),
null
,
this
.
onConnectStatusChanged
);
}
else
if
(
this
.
authentication
===
_converse
.
LOGIN
)
{
var
password
=
_
converse
.
connection
.
pass
||
thi
s
.
password
;
var
password
=
_
.
isNil
(
credentials
)
?
(
_converse
.
connection
.
pass
||
this
.
password
)
:
credential
s
.
password
;
if
(
!
password
)
{
if
(
this
.
auto_login
&&
!
this
.
password
)
{
if
(
this
.
auto_login
)
{
throw
new
Error
(
"
initConnection: If you use auto_login and
"
+
"
authentication='login' then you also need to provide a password.
"
);
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment