fixed single character custom emoji

This commit is contained in:
supertiger1234 2019-08-03 11:30:44 +01:00
parent 124e9a7f22
commit 1d2a22a40c
2 changed files with 4 additions and 1 deletions

View file

@ -25,6 +25,9 @@ const config = [
"Remove '13 or under' option in the survey.",
"Redesigned user information pop-out which now shows the badges for developer, creator and more."
],
fix: [
"Issues fixed where custom emojis with single character did not work."
]
},
{
version: 5.6,

View file

@ -69,7 +69,7 @@ function replace_custom_emoji(state, silent) {
// console.log(nameEnd, parseUntil(state,nameStart,58))
// parser failed to find another ':', so it's not a valid emoji
if(nameEnd > max || nameEnd < 0 || nameEnd - nameStart <= 1) { return false; }
if(nameEnd > max || nameEnd < 0 || nameEnd - nameStart <= 0) { return false; }
let emojiName = state.src.slice(nameStart, nameEnd)