diff --git a/pom.xml b/pom.xml index 8fab64f..ef1418b 100644 --- a/pom.xml +++ b/pom.xml @@ -6,7 +6,7 @@ tsp.headdb HeadDB - 5.0.0-rc.9 + 5.0.0-rc.10 jar HeadDB @@ -75,7 +75,7 @@ com.github.TheSilentPro NexusLib - 9d8b16b770 + 45b4813899 com.github.TheSilentPro diff --git a/src/main/java/tsp/headdb/core/util/Utils.java b/src/main/java/tsp/headdb/core/util/Utils.java index 8005311..a538d40 100644 --- a/src/main/java/tsp/headdb/core/util/Utils.java +++ b/src/main/java/tsp/headdb/core/util/Utils.java @@ -281,7 +281,8 @@ public class Utils { ItemMeta meta = item.getItemMeta(); // if version < 1.20.1 use reflection, else (1.20.2+) use PlayerProfile because spigot bitches otherwise. - if (ServerVersion.getVersion().orElse(ServerVersion.v_1_20_1).isOlderThan(ServerVersion.v_1_20_2)) { + // Assumes newer version has been released when optional is empty. + if (ServerVersion.getVersion().orElse(ServerVersion.v_1_20_2).isOlderThan(ServerVersion.v_1_20_1)) { try { GameProfile profile = new GameProfile(head.getUniqueId(), head.getName()); profile.getProperties().put("textures", new Property("textures", head.getTexture()));