mirror of
https://github.com/HibiscusMC/HMCCosmetics.git
synced 2025-12-30 04:19:28 +00:00
clean: worldguard listener moved to isEmpty from == 0
This commit is contained in:
@@ -31,7 +31,7 @@ public class WGListener implements Listener {
|
||||
Location location = event.getPlayer().getLocation();
|
||||
ApplicableRegionSet set = getRegions(location);
|
||||
if (user.getHidden()) {
|
||||
if (user.getHiddenReason() == CosmeticUser.HiddenReason.WORLDGUARD && set.getRegions().size() == 0) {
|
||||
if (user.getHiddenReason() == CosmeticUser.HiddenReason.WORLDGUARD && set.getRegions().isEmpty()) {
|
||||
user.showCosmetics();
|
||||
}
|
||||
}
|
||||
@@ -59,7 +59,7 @@ public class WGListener implements Listener {
|
||||
Location location = event.getTo();
|
||||
ApplicableRegionSet set = getRegions(location);
|
||||
if (user.getHidden()) {
|
||||
if (user.getHiddenReason() == CosmeticUser.HiddenReason.WORLDGUARD && set.getRegions().size() == 0) {
|
||||
if (user.getHiddenReason() == CosmeticUser.HiddenReason.WORLDGUARD && set.getRegions().isEmpty()) {
|
||||
user.showCosmetics();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user