aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/serve.js6
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/serve.js b/lib/serve.js
index c1353aa..9d5eb82 100644
--- a/lib/serve.js
+++ b/lib/serve.js
@@ -2237,12 +2237,18 @@ Serve.prototype.getBuiltinEmojiLink = function (name) {
Serve.prototype.emojis = function (path) {
var self = this
+ var seen = {}
pull(
ph('section', [
ph('h3', 'Emojis'),
ph('ul', {class: 'mentions'}, pull(
self.app.streamEmojis(),
pull.map(function (emoji) {
+ if (!seen[emoji.name]) {
+ // cache the first use, so that our uses take precedence over other feeds'
+ self.app.reverseEmojiNameCache.set(emoji.name, emoji.link)
+ seen[emoji.name] = true
+ }
return ph('li', [
ph('a', {href: self.app.render.toUrl('/links/' + emoji.link)},
ph('img', {