diff --git a/src/main/java/com/gamingmesh/jobs/PermissionHandler.java b/src/main/java/com/gamingmesh/jobs/PermissionHandler.java index aad5b251..182d528f 100644 --- a/src/main/java/com/gamingmesh/jobs/PermissionHandler.java +++ b/src/main/java/com/gamingmesh/jobs/PermissionHandler.java @@ -35,7 +35,6 @@ import com.gamingmesh.jobs.container.JobConditions; import com.gamingmesh.jobs.container.JobPermission; import com.gamingmesh.jobs.container.JobProgression; import com.gamingmesh.jobs.container.JobsPlayer; -import com.gamingmesh.jobs.stuff.Debug; public class PermissionHandler { private Jobs plugin; diff --git a/src/main/java/com/gamingmesh/jobs/container/JobConditions.java b/src/main/java/com/gamingmesh/jobs/container/JobConditions.java index d5e69ebc..e69e4f31 100644 --- a/src/main/java/com/gamingmesh/jobs/container/JobConditions.java +++ b/src/main/java/com/gamingmesh/jobs/container/JobConditions.java @@ -49,9 +49,14 @@ public class JobConditions { for (String one : perform) { if (!one.toLowerCase().contains("p:")) continue; - String perm = one.toLowerCase().replace("p:", "").split("-")[0]; - boolean n = one.toLowerCase().replace("p:", "").split("-")[1].equalsIgnoreCase("true") ? true : false; - performPerm.put(perm, n); + String clean = one.toLowerCase().substring("p:".length()); + if (clean.contains("-")) { + String perm = clean.split("-")[0]; + boolean n = clean.split("-")[1].equalsIgnoreCase("true") ? true : false; + performPerm.put(perm, n); + } else { + performPerm.put(clean, true); + } } }