skip undefined emotes
This commit is contained in:
parent
5824f03253
commit
9eb0976b35
1 changed files with 1 additions and 0 deletions
|
@ -57,6 +57,7 @@ async function process_text(text: string): Promise<string> {
|
||||||
for (const emote of matches.reverse()) {
|
for (const emote of matches.reverse()) {
|
||||||
const [match, code] = emote;
|
const [match, code] = emote;
|
||||||
const index = emote.index ?? 0;
|
const index = emote.index ?? 0;
|
||||||
|
if (!(code in emotes)) continue;
|
||||||
|
|
||||||
text =
|
text =
|
||||||
text.substring(0, index) +
|
text.substring(0, index) +
|
||||||
|
|
Loading…
Reference in a new issue