Wait until emojis are initialized...

before adding them to the message body
This commit is contained in:
JC Brand 2020-06-24 12:19:49 +02:00
parent b3e34a0636
commit 1b520328fa

View File

@ -32,6 +32,7 @@ class MessageBodyRenderer extends String {
let list = await Promise.all(u.addHyperlinks(text));
await api.waitUntil('emojisInitialized');
list = list.reduce((acc, i) => isString(i) ? [...acc, ...u.addEmoji(i)] : [...acc, i], []);
const addMentions = text => addMentionsMarkup(text, this.model.get('references'), this.model.collection.chatbox)