diff options
author | Harmon <Harmon758@gmail.com> | 2018-04-07 07:53:11 -0500 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2018-04-07 14:53:11 +0200 |
commit | 98146281e1beaf994710b13ef70f6224e8588cba (patch) | |
tree | 600a5ab893a61b9b5f49711f714d721eb0a1e690 /app/javascript | |
parent | b08ab329f4d149fd414e0539574f49062c571a8a (diff) |
Remove duplicate frequently used emojis (#7064)
Diffstat (limited to 'app/javascript')
-rw-r--r-- | app/javascript/mastodon/features/compose/containers/emoji_picker_dropdown_container.js | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/app/javascript/mastodon/features/compose/containers/emoji_picker_dropdown_container.js b/app/javascript/mastodon/features/compose/containers/emoji_picker_dropdown_container.js index e6a535a5d..5ec937a39 100644 --- a/app/javascript/mastodon/features/compose/containers/emoji_picker_dropdown_container.js +++ b/app/javascript/mastodon/features/compose/containers/emoji_picker_dropdown_container.js @@ -38,7 +38,8 @@ const getFrequentlyUsedEmojis = createSelector([ .toArray(); if (emojis.length < DEFAULTS.length) { - emojis = emojis.concat(DEFAULTS.slice(0, DEFAULTS.length - emojis.length)); + let uniqueDefaults = DEFAULTS.filter(emoji => !emojis.includes(emoji)); + emojis = emojis.concat(uniqueDefaults.slice(0, DEFAULTS.length - emojis.length)); } return emojis; |