Commit 5738b374 authored by JC Brand's avatar JC Brand

Use `getDisplayName` for roster contacts

parent 1fb53785
......@@ -2094,7 +2094,7 @@ converse.plugins.add('converse-muc-views', {
return;
}
form.addEventListener('submit', this.inviteFormSubmitted.bind(this), false);
const list = _converse.roster.map(i => ({'label': i.get('fullname') || i.get('jid'), 'value': i.get('jid')}));
const list = _converse.roster.map(i => ({'label': i.getDisplayName(), 'value': i.get('jid')}));
const el = this.el.querySelector('.suggestion-box').parentElement;
if (this.invite_auto_complete) {
......
......@@ -1560,7 +1560,7 @@ converse.plugins.add('converse-muc', {
result = true;
} else {
// Invite request might come from someone not your roster list
contact = contact? contact.get('fullname'): Strophe.getNodeFromJid(from);
contact = contact? contact.getDisplayName(): Strophe.getNodeFromJid(from);
if (!reason) {
result = confirm(
__("%1$s has invited you to join a groupchat: %2$s", contact, room_jid)
......
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