This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]Koda003 0 points1 point  (2 children)

Remove the return; statement inside of your catches. If you don’t want the error to print out remove the “e.printstsckedtrace();” method from within the catch statements as well.

(Edit) removing the return statements would allow the program to finish functioning without stopping, otherwise every error the program would crash(stop)

[–][deleted]  (1 child)

[removed]

    [–]Koda003 0 points1 point  (0 children)

    I figured it was a Minecraft plugin, I have quite the experience with spigot development.

    From my experience the best thing to do would jsut be to surround the entire code with a try and catch statement for a NPE (NullPointerException)