SPIGOT-4112: scoreboard display names are not nullable

Dieser Commit ist enthalten in:
md_5 2018-07-23 11:46:23 +10:00
Ursprung d4297cbe2d
Commit 155b17305b
2 geänderte Dateien mit 2 neuen und 2 gelöschten Zeilen

Datei anzeigen

@ -42,7 +42,7 @@ final class CraftObjective extends CraftScoreboardComponent implements Objective
Validate.isTrue(displayName.length() <= 128, "Display name '" + displayName + "' is longer than the limit of 128 characters");
CraftScoreboard scoreboard = checkState();
objective.setDisplayName(CraftChatMessage.fromStringOrNull(displayName));
objective.setDisplayName(CraftChatMessage.fromString(displayName)[0]); // SPIGOT-4112: not nullable
}
public String getCriteria() throws IllegalStateException {

Datei anzeigen

@ -41,7 +41,7 @@ final class CraftTeam extends CraftScoreboardComponent implements Team {
Validate.isTrue(displayName.length() <= 128, "Display name '" + displayName + "' is longer than the limit of 128 characters");
CraftScoreboard scoreboard = checkState();
team.setDisplayName(CraftChatMessage.fromStringOrNull(displayName));
team.setDisplayName(CraftChatMessage.fromString(displayName)[0]); // SPIGOT-4112: not nullable
}
public String getPrefix() throws IllegalStateException {