Skip to content

Commit

Permalink
Prevent fake players from causing issues
Browse files Browse the repository at this point in the history
  • Loading branch information
Redstonneur1256 committed May 12, 2023
1 parent b4cc798 commit 79779eb
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ public class PlayerMixin implements NetworkDebuggable {

@Override
public long getPing() {
return ((NetworkDebuggable) con).getPing();
return con instanceof NetworkDebuggable ? ((NetworkDebuggable) con).getPing() : -1;
}

}

0 comments on commit 79779eb

Please sign in to comment.