Gikkman / Java-Twirk

Small, basic library for communication via the Twitch chat. Java 8 compatible
MIT License
54 stars 22 forks source link

NumberFormatException on bit emotes #22

Closed Gikkman closed 4 years ago

Gikkman commented 4 years ago

I got a report on Discord:

The issue seems to occur when people enter a bit emote, but I don't got more details at the moment.

java.lang.NumberFormatException: For input string: "emotesv2"
    at java.lang.NumberFormatException.forInputString(NumberFormatException.java:65)
    at java.lang.Integer.parseInt(Integer.java:580)
    at java.lang.Integer.parseInt(Integer.java:615)
    at com.gikk.twirk.types.emote.EmoteParserImpl.finalizeEmote(EmoteParserImpl.java:75)
    at com.gikk.twirk.types.emote.EmoteParserImpl.parseEmotes(EmoteParserImpl.java:64)
    at com.gikk.twirk.types.twitchMessage.DefaultTwitchMessageBuilder.build(DefaultTwitchMessageBuilder.java:37)
    at com.gikk.twirk.Twirk.incommingMessage(Twirk.java:461)
    at com.gikk.twirk.InputThread.run(InputThread.java:43)