Check for blank OfflinePlayer Names

By: md_5 <git@md-5.net>
This commit is contained in:
CraftBukkit/Spigot
2019-01-05 16:21:07 +11:00
parent d19f284744
commit bda697612e

View File

@@ -1318,6 +1318,7 @@ public final class CraftServer implements Server {
@Deprecated
public OfflinePlayer getOfflinePlayer(String name) {
Validate.notNull(name, "Name cannot be null");
Validate.notEmpty(name, "Name cannot be empty");
OfflinePlayer result = getPlayerExact(name);
if (result == null) {