mirror of
https://github.com/IntellectualSites/PlotSquared.git
synced 2024-11-25 14:46:45 +01:00
fixed bugs
This commit is contained in:
parent
487aa93986
commit
12c476f3c2
@ -71,7 +71,7 @@ public class FlagManager {
|
|||||||
public static List<AbstractFlag> getFlags(final Player player) {
|
public static List<AbstractFlag> getFlags(final Player player) {
|
||||||
final List<AbstractFlag> returnFlags = new ArrayList<>();
|
final List<AbstractFlag> returnFlags = new ArrayList<>();
|
||||||
for (final AbstractFlag flag : flags) {
|
for (final AbstractFlag flag : flags) {
|
||||||
if (player.hasPermission("plots.set." + flag.getKey().toLowerCase())) {
|
if (player.hasPermission("plots.set.flag." + flag.getKey().toLowerCase())) {
|
||||||
returnFlags.add(flag);
|
returnFlags.add(flag);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -262,7 +262,13 @@ public class Set extends SubCommand {
|
|||||||
sendMessage(plr, C.NAME_LITTLE, "Material", args[1].length() + "", "2");
|
sendMessage(plr, C.NAME_LITTLE, "Material", args[1].length() + "", "2");
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
final Material material = getMaterial(args[1], PlotWorld.BLOCKS);
|
Material material;
|
||||||
|
try {
|
||||||
|
material = getMaterial(args[1], PlotWorld.BLOCKS);
|
||||||
|
}
|
||||||
|
catch (NullPointerException e) {
|
||||||
|
material = null;
|
||||||
|
}
|
||||||
/*
|
/*
|
||||||
* for (Material m : PlotWorld.BLOCKS) {
|
* for (Material m : PlotWorld.BLOCKS) {
|
||||||
* if (m.toString().equalsIgnoreCase(args[1])) {
|
* if (m.toString().equalsIgnoreCase(args[1])) {
|
||||||
|
Loading…
Reference in New Issue
Block a user