Fix node test for emojis.

This fixes the node test for emojis that broke when the type for
displaying the emojis in the popover changed to an object from a string.
This commit is contained in:
Brock Whittaker 2017-01-27 16:39:14 -08:00 committed by Tim Abbott
parent 1535739222
commit 22b74a9e01
1 changed files with 17 additions and 3 deletions

View File

@ -377,9 +377,23 @@ function render(template_name, args) {
}());
(function emoji_popover_content() {
var args = {
emoji_list: global.emoji.emojis_name_to_css_class,
var args = (function () {
var map = {};
for (var x in global.emoji.emojis_name_to_css_class) {
if (!global.emoji.realm_emojis[x]) {
map[x] = {
name: x,
css_name: global.emoji.emojis_name_to_css_class[x],
url: global.emoji.emojis_by_name[x],
};
}
}
return {
emoji_list: map,
realm_emoji: global.emoji.realm_emojis,
};
}());
var html = '<div style="height: 250px">';
html += render('emoji_popover_content', args);