if a toaster is interacted with non player element, when it finishes toasting a toast, it toasts the server
SRAZKVT opened this issue ยท 2 comments
Whenever a toaster is interacted with non player element, the variable lastUser isn't set to anything, it stays as null, when the toaster finishes toasting it just ends up crashing the server because the toaster checks for last user to increment a statistic (i suppose), but in this case, the last user is null, which causes a null pointer exception.
crash-2022-02-26_12.57.38-server.txt
Where it fails:
as you can see, here the line contains if (!world.isClient()) {
and then directly goes on to the player uuid
easiest way to fix imo would be to just change that line to if (!world.isClient() && this.lastUser != null) {
Might be related to #126 , since the logs seem extremely similar, and the stacktraces are basically identical, although i am not 100% sure