Add null check

This commit is contained in:
fullwall 2022-07-13 20:10:42 +08:00
parent 4dfac9c62d
commit f462fe9218

View File

@ -37,6 +37,8 @@ public class ScoreboardTrait extends Trait {
public void apply(boolean nameVisibility) { public void apply(boolean nameVisibility) {
Team team = getTeam(); Team team = getTeam();
if (team == null)
return;
if (!Setting.USE_SCOREBOARD_TEAMS.asBoolean()) { if (!Setting.USE_SCOREBOARD_TEAMS.asBoolean()) {
team.unregister(); team.unregister();