Commit 8dcb327e authored by André Berenguel's avatar André Berenguel Committed by JC Brand

Update contact nickname when receive a roster push

parent e5c7e47b
......@@ -20,6 +20,7 @@
- #1417 Margin between nickname and badge
- #1421 Fix direct invite for membersonly room
- #1422 Resurrect the `muc_show_join_leave` option
- #1438 Update contact nickname when receiving a roster push
- #1442 MUC read receipts causing empty lines
## 4.1.0 (2019-01-11)
......
......@@ -68673,6 +68673,7 @@ _converse_headless_converse_core__WEBPACK_IMPORTED_MODULE_0__["default"].plugins
contact.save({
'subscription': subscription,
'ask': ask,
'nickname': item.getAttribute("name"),
'requesting': null,
'groups': groups
});
......@@ -270,7 +270,7 @@
.c('item', {
'jid': 'contact@example.org',
'subscription': 'to',
'name': 'contact@example.org'});
'name': 'Nicky'});
_converse.connection._dataRecv(test_utils.createRequest(stanza));
// Check that the IQ set was acknowledged.
expect(sent_stanza.toLocaleString()).toBe( // Strophe adds the xmlns attr (although not in spec)
......@@ -294,7 +294,7 @@
expect($contacts.hasClass('to')).toBeTruthy();
expect($contacts.hasClass('both')).toBeFalsy();
expect($contacts.hasClass('current-xmpp-contact')).toBeTruthy();
expect($contacts.text().trim()).toBe('Contact');
expect($contacts.text().trim()).toBe('Nicky');
expect(contact.presence.get('show')).toBe('offline');
/* <presence
......
......@@ -627,6 +627,7 @@ converse.plugins.add('converse-roster', {
contact.save({
'subscription': subscription,
'ask': ask,
'nickname': item.getAttribute("name"),
'requesting': null,
'groups': groups
});
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment