BigW Consortium Gitlab

Commit a8140d5c by Eric Eastwood
parent e6fc0207
...@@ -444,7 +444,7 @@ AwardsHandler.prototype.scrollToAwards = function scrollToAwards() { ...@@ -444,7 +444,7 @@ AwardsHandler.prototype.scrollToAwards = function scrollToAwards() {
}; };
AwardsHandler.prototype.normalizeEmojiName = function normalizeEmojiName(emoji) { AwardsHandler.prototype.normalizeEmojiName = function normalizeEmojiName(emoji) {
return this.aliases[emoji] || emoji; return Object.prototype.hasOwnProperty.call(this.aliases, emoji) ? this.aliases[emoji] : emoji;
}; };
AwardsHandler AwardsHandler
......
...@@ -16,7 +16,8 @@ const glEmojiTagDefaults = { ...@@ -16,7 +16,8 @@ const glEmojiTagDefaults = {
}; };
function glEmojiTag(inputName, options) { function glEmojiTag(inputName, options) {
const opts = Object.assign({}, glEmojiTagDefaults, options); const opts = Object.assign({}, glEmojiTagDefaults, options);
const name = emojiAliases[inputName] || inputName; const name = Object.prototype.hasOwnProperty.call(emojiAliases, inputName) ?
emojiAliases[inputName] : inputName;
const emojiInfo = emojiMap[name]; const emojiInfo = emojiMap[name];
const fallbackImageSrc = `${gon.relative_url_root || ''}/assets/emoji/${name}-${emojiInfo.digest}.png`; const fallbackImageSrc = `${gon.relative_url_root || ''}/assets/emoji/${name}-${emojiInfo.digest}.png`;
const fallbackSpriteClass = `emoji-${name}`; const fallbackSpriteClass = `emoji-${name}`;
......
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