Skip to content

Commit

Permalink
UserNotice#parseEmotes: bail early if there's no message text
Browse files Browse the repository at this point in the history
  • Loading branch information
d-fischer committed Feb 25, 2020
1 parent 888c51d commit 9922468
Showing 1 changed file with 5 additions and 0 deletions.
Expand Up @@ -35,6 +35,11 @@ export default class UserNotice extends Message<UserNotice> {

parseEmotes() {
const messageText = this.params.message;

if (!messageText) {
return [];
}

const foundEmotes: ParsedMessagePart[] = parseEmotePositions(messageText, this.emoteOffsets);

return fillTextPositions(messageText, foundEmotes);
Expand Down

0 comments on commit 9922468

Please sign in to comment.