mirror of
https://github.com/darksaid98/HuskHomes.git
synced 2026-12-01 22:16:08 +00:00
Add warp permissions override, closes #30
This commit is contained in:
1 parent
9784623d45
commit
e5d265a155
2 files changed
+4
No files matched your search
@@ -79,6 +79,7 @@ public class Warp extends TeleportationPoint {
|
||||
}
|
||||
p.recalculatePermissions();
|
||||
String permissionFormat = HuskHomes.getSettings().getWarpRestrictionPermissionFormat();
|
||||
if (p.hasPermission("huskhomes.warp.*") || p.hasPermission(permissionFormat + "*")) { return true; } // Always return true if they have the wildcard
|
||||
for (PermissionAttachmentInfo permissionAI : p.getEffectivePermissions()) {
|
||||
String permission = permissionAI.getPermission();
|
||||
if (permission.contains(permissionFormat)) {
|
||||
|
||||
Reference in new issue
Block a user