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
24956d8d
Commit
24956d8d
authored
May 30, 2019
by
JC Brand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Execute manual resource binding if necessary
parent
0688907e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
0 deletions
+12
-0
src/headless/converse-core.js
src/headless/converse-core.js
+12
-0
No files found.
src/headless/converse-core.js
View file @
24956d8d
...
@@ -849,6 +849,8 @@ _converse.initialize = async function (settings, callback) {
...
@@ -849,6 +849,8 @@ _converse.initialize = async function (settings, callback) {
}
else
if
(
status
===
Strophe
.
Status
.
DISCONNECTED
)
{
}
else
if
(
status
===
Strophe
.
Status
.
DISCONNECTED
)
{
_converse
.
setDisconnectionCause
(
status
,
message
);
_converse
.
setDisconnectionCause
(
status
,
message
);
_converse
.
onDisconnected
();
_converse
.
onDisconnected
();
}
else
if
(
status
===
Strophe
.
Status
.
BINDREQUIRED
)
{
_converse
.
bindResource
();
}
else
if
(
status
===
Strophe
.
Status
.
ERROR
)
{
}
else
if
(
status
===
Strophe
.
Status
.
ERROR
)
{
_converse
.
setConnectionStatus
(
_converse
.
setConnectionStatus
(
status
,
status
,
...
@@ -1089,6 +1091,16 @@ _converse.initialize = async function (settings, callback) {
...
@@ -1089,6 +1091,16 @@ _converse.initialize = async function (settings, callback) {
_converse
.
api
.
trigger
(
'
setUserJID
'
);
_converse
.
api
.
trigger
(
'
setUserJID
'
);
};
};
this
.
bindResource
=
async
function
()
{
/**
* Synchronous event triggered before we send an IQ to bind the user's
* JID resource for this session.
* @event _converse#beforeResourceBinding
*/
await
_converse
.
api
.
trigger
(
'
beforeResourceBinding
'
,
{
'
synchronous
'
:
true
});
_converse
.
connection
.
bind
();
};
this
.
onConnected
=
function
(
reconnecting
)
{
this
.
onConnected
=
function
(
reconnecting
)
{
/* Called as soon as a new connection has been established, either
/* Called as soon as a new connection has been established, either
* by logging in or by attaching to an existing BOSH session.
* by logging in or by attaching to an existing BOSH session.
...
...
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