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
7e94f3c6
Commit
7e94f3c6
authored
May 07, 2018
by
JC Brand
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Bugfix. Send model instance to event listeners
So that we can call `getDisplayName`
parent
b8679063
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
3 deletions
+5
-3
docs/source/events.rst
docs/source/events.rst
+4
-1
src/converse-roster.js
src/converse-roster.js
+1
-2
No files found.
docs/source/events.rst
View file @
7e94f3c6
...
@@ -161,7 +161,10 @@ contactRequest
...
@@ -161,7 +161,10 @@ contactRequest
Someone has requested to subscribe to your presence (i.e. to be your contact).
Someone has requested to subscribe to your presence (i.e. to be your contact).
``_converse.api.listen.on('contactRequest', function (user_data) { ... });``
The `Backbone.Model <http://backbonejs.org/#Model>`_ instance representing the
roster contact is passed to the event listener.
``_converse.api.listen.on('contactRequest', function (contact) { ... });``
contactRemoved
contactRemoved
~~~~~~~~~~~~~~
~~~~~~~~~~~~~~
...
...
src/converse-roster.js
View file @
7e94f3c6
...
@@ -600,8 +600,7 @@
...
@@ -600,8 +600,7 @@
'
requesting
'
:
true
,
'
requesting
'
:
true
,
'
nickname
'
:
nickname
'
nickname
'
:
nickname
};
};
this
.
create
(
user_data
);
_converse
.
emit
(
'
contactRequest
'
,
this
.
create
(
user_data
));
_converse
.
emit
(
'
contactRequest
'
,
user_data
);
},
},
handleIncomingSubscription
(
presence
)
{
handleIncomingSubscription
(
presence
)
{
...
...
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