tbackus127 / RathBot

A Discord bot for osu!-related channels.
MIT License
2 stars 1 forks source link

Error Fix: NullPointerException when running Admin Commands #15

Closed ghost closed 6 years ago

ghost commented 6 years ago

Stack Trace:

10:14:12.275: [ERROR][Event Dispatcher Handler][sx.blah.discord.Discord4J] - Unhandled exception caught dispatching event MessageReceivedEvent
java.lang.NullPointerException
    at com.rath.rathbot.RathBot.kickUser(RathBot.java:151)
    at com.rath.rathbot.cmd.disc.actions.KickCmd.executeCommand(KickCmd.java:88)
    at com.rath.rathbot.CommandParser.parseCommand(CommandParser.java:81)
    at com.rath.rathbot.EventHandler.onMessageReceived(EventHandler.java:46)
    at sx.blah.discord.api.events.EventDispatcher$MethodEventHandler.handle(EventDispatcher.java:680)
    at sx.blah.discord.api.events.EventDispatcher.lambda$null$17(EventDispatcher.java:610)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
tbackus127 commented 6 years ago

Done.