diff --git a/gradlew b/gradlew old mode 100644 new mode 100755 diff --git a/worldguard-legacy/src/main/java/com/sk89q/worldguard/bukkit/listener/WorldGuardPlayerListener.java b/worldguard-legacy/src/main/java/com/sk89q/worldguard/bukkit/listener/WorldGuardPlayerListener.java index 05087c35..5b4fa67d 100644 --- a/worldguard-legacy/src/main/java/com/sk89q/worldguard/bukkit/listener/WorldGuardPlayerListener.java +++ b/worldguard-legacy/src/main/java/com/sk89q/worldguard/bukkit/listener/WorldGuardPlayerListener.java @@ -175,7 +175,11 @@ public void onPlayerLogin(PlayerLoginEvent event) { Player player = event.getPlayer(); ConfigurationManager cfg = plugin.getGlobalStateManager(); - String hostKey = cfg.hostKeys.get(player.getName().toLowerCase()); + String hostKey = cfg.hostKeys.get(player.getUniqueId().toString()); + if (hostKey == null) { + hostKey = cfg.hostKeys.get(player.getName().toLowerCase()); + } + if (hostKey != null) { String hostname = event.getHostname(); int colonIndex = hostname.indexOf(':');