Fixed messenger real name display.

This commit is contained in:
Ylian Saint-Hilaire 2021-01-27 15:32:00 -08:00
parent 69d59235bc
commit 7bbba5215a
2 changed files with 1 additions and 6620 deletions

File diff suppressed because it is too large Load Diff

View File

@ -2759,7 +2759,7 @@ module.exports.CreateWebServer = function (parent, db, args, certificates) {
if (idSplit.length == 7) { if (idSplit.length == 7) {
const user = obj.users[idSplit[4] + '/' + idSplit[5] + '/' + idSplit[6]]; const user = obj.users[idSplit[4] + '/' + idSplit[5] + '/' + idSplit[6]];
if (user != null) { if (user != null) {
if (domain.meshmessengertitle.indexOf('{0}') >= 0) { options.username = encodeURIComponent(user.name ? user.name : user._id.split('/')[2]).replace(/'/g, '%27'); } if (domain.meshmessengertitle.indexOf('{0}') >= 0) { options.username = encodeURIComponent(user.realname ? user.realname : user._id.split('/')[2]).replace(/'/g, '%27'); }
if (domain.meshmessengertitle.indexOf('{1}') >= 0) { options.userid = encodeURIComponent(user._id.split('/')[2]).replace(/'/g, '%27'); } if (domain.meshmessengertitle.indexOf('{1}') >= 0) { options.userid = encodeURIComponent(user._id.split('/')[2]).replace(/'/g, '%27'); }
} }
} }