This commit is contained in:
Jesse Boyd 2015-10-21 16:34:15 +11:00
parent fa442f5903
commit a6dad4fb7b
3 changed files with 6 additions and 1 deletions

2
CONTRIBUTING.md Normal file
View File

@ -0,0 +1,2 @@
### Bugs
Please provide a `/plot debugpaste` if you are reporting a bug.

View File

@ -14,7 +14,7 @@ public class Permissions {
} }
public static boolean hasPermission(final CommandCaller player, String perm) { public static boolean hasPermission(final CommandCaller player, String perm) {
if (player.hasPermission(perm)) { if (player.hasPermission(perm) || player.hasPermission(C.PERMISSION_ADMIN.s())) {
return true; return true;
} }
perm = perm.toLowerCase().replaceAll("^[^a-z|0-9|\\.|_|-]", ""); perm = perm.toLowerCase().replaceAll("^[^a-z|0-9|\\.|_|-]", "");
@ -42,6 +42,9 @@ public class Permissions {
} }
public static int hasPermissionRange(final PlotPlayer player, final String stub, final int range) { public static int hasPermissionRange(final PlotPlayer player, final String stub, final int range) {
if (player.hasPermission(C.PERMISSION_ADMIN.s())) {
return Integer.MAX_VALUE;
}
final String[] nodes = stub.split("\\."); final String[] nodes = stub.split("\\.");
final StringBuilder n = new StringBuilder(); final StringBuilder n = new StringBuilder();
for (int i = 0; i < (nodes.length - 1); i++) { for (int i = 0; i < (nodes.length - 1); i++) {

Binary file not shown.