From f23f04fdb11cb873082567a2b949162cc1d2d832 Mon Sep 17 00:00:00 2001 From: cnr Date: Thu, 19 Jan 2017 14:56:15 -0600 Subject: [PATCH] Fix NPE in getOrLoadClient --- .../src/mineplex/core/account/CoreClientManager.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/Plugins/Mineplex.Core/src/mineplex/core/account/CoreClientManager.java b/Plugins/Mineplex.Core/src/mineplex/core/account/CoreClientManager.java index 8b32bbee5..79bccee81 100644 --- a/Plugins/Mineplex.Core/src/mineplex/core/account/CoreClientManager.java +++ b/Plugins/Mineplex.Core/src/mineplex/core/account/CoreClientManager.java @@ -45,7 +45,6 @@ import mineplex.core.common.util.Callback; import mineplex.core.common.util.UUIDFetcher; import mineplex.core.common.util.UtilPlayer; import mineplex.core.common.util.UtilTasks; -import mineplex.core.portal.Portal; import mineplex.core.updater.UpdateType; import mineplex.core.updater.event.UpdateEvent; import mineplex.core.utils.UtilGameProfile; @@ -138,7 +137,7 @@ public class CoreClientManager extends MiniPlugin public CoreClient Get(String name) { Player p = Bukkit.getPlayerExact(name); - return Get(p.getUniqueId()); + return p != null ? Get(p.getUniqueId()) : null; } public CoreClient Get(UUID uuid)