From 63adfb166cd5ebae658a25fbaa8856dc43cc0e56 Mon Sep 17 00:00:00 2001 From: Zrips Date: Wed, 14 Mar 2018 15:45:07 +0200 Subject: [PATCH] Small fix for new player with null name --- src/main/java/com/gamingmesh/jobs/PlayerManager.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/gamingmesh/jobs/PlayerManager.java b/src/main/java/com/gamingmesh/jobs/PlayerManager.java index 141130e0..9ca1b04d 100644 --- a/src/main/java/com/gamingmesh/jobs/PlayerManager.java +++ b/src/main/java/com/gamingmesh/jobs/PlayerManager.java @@ -106,7 +106,8 @@ public class PlayerManager { public void addPlayerToMap(PlayerInfo info) { this.PlayerUUIDMap.put(info.getUuid(), info); this.PlayerIDMap.put(info.getID(), info); - this.PlayerNameMap.put(info.getName().toLowerCase(), info); + if (info.getName() != null) + this.PlayerNameMap.put(info.getName().toLowerCase(), info); } public void addPlayerToCache(JobsPlayer jPlayer) {