Skip to content

Commit

Permalink
Fixed a NPE when creating a SuperiorPlayer object for a player that d…
Browse files Browse the repository at this point in the history
…oesn't exist
  • Loading branch information
OmerBenGera committed Oct 1, 2022
1 parent 5a2d42a commit 1fb8f96
Showing 1 changed file with 1 addition and 1 deletion.
Expand Up @@ -141,7 +141,7 @@ public SuperiorPlayer createPlayer(UUID playerUUID) {
SuperiorPlayer.Builder builder = createPlayerBuilder()
.setUniqueId(playerUUID);

if (offlinePlayer != null)
if (offlinePlayer != null && offlinePlayer.getName() != null)
builder.setName(offlinePlayer.getName());

return builder.build();
Expand Down

0 comments on commit 1fb8f96

Please sign in to comment.