mirror of
				https://github.com/IntellectualSites/PlotSquared.git
				synced 2025-11-04 03:03:43 +01:00 
			
		
		
		
	Fix errors *again
This commit is contained in:
		@@ -74,7 +74,7 @@ public class Add extends SubCommand {
 | 
			
		||||
        if (args[0].equalsIgnoreCase("*")) {
 | 
			
		||||
            uuid = DBFunc.everyone;
 | 
			
		||||
        } else {
 | 
			
		||||
            uuid = UUIDHandler.getUUID(args[0]);
 | 
			
		||||
            uuid = UUIDHandler.getUUID(args[0], null);
 | 
			
		||||
        }
 | 
			
		||||
        if (uuid == null) {
 | 
			
		||||
            if (UUIDHandler.implementation instanceof SQLUUIDHandler) {
 | 
			
		||||
 
 | 
			
		||||
@@ -332,7 +332,7 @@ public class Cluster extends SubCommand {
 | 
			
		||||
                    }
 | 
			
		||||
                }
 | 
			
		||||
                // check uuid
 | 
			
		||||
                final UUID uuid = UUIDHandler.getUUID(args[1]);
 | 
			
		||||
                final UUID uuid = UUIDHandler.getUUID(args[1], null);
 | 
			
		||||
                if (uuid == null) {
 | 
			
		||||
                    MainUtil.sendMessage(plr, C.INVALID_PLAYER, args[2]);
 | 
			
		||||
                    return false;
 | 
			
		||||
@@ -373,7 +373,7 @@ public class Cluster extends SubCommand {
 | 
			
		||||
                    }
 | 
			
		||||
                }
 | 
			
		||||
                // check uuid
 | 
			
		||||
                final UUID uuid = UUIDHandler.getUUID(args[1]);
 | 
			
		||||
                final UUID uuid = UUIDHandler.getUUID(args[1], null);
 | 
			
		||||
                if (uuid == null) {
 | 
			
		||||
                    MainUtil.sendMessage(plr, C.INVALID_PLAYER, args[1]);
 | 
			
		||||
                    return false;
 | 
			
		||||
@@ -468,7 +468,7 @@ public class Cluster extends SubCommand {
 | 
			
		||||
                    MainUtil.sendMessage(plr, C.NOT_IN_CLUSTER);
 | 
			
		||||
                    return false;
 | 
			
		||||
                }
 | 
			
		||||
                final UUID uuid = UUIDHandler.getUUID(args[2]);
 | 
			
		||||
                final UUID uuid = UUIDHandler.getUUID(args[2], null);
 | 
			
		||||
                if (uuid == null) {
 | 
			
		||||
                    MainUtil.sendMessage(plr, C.INVALID_PLAYER, args[2]);
 | 
			
		||||
                    return false;
 | 
			
		||||
 
 | 
			
		||||
@@ -121,7 +121,7 @@ public class DebugClaimTest extends SubCommand {
 | 
			
		||||
                        }
 | 
			
		||||
                    }
 | 
			
		||||
                    if (uuid == null) {
 | 
			
		||||
                        uuid = UUIDHandler.getUUID(line);
 | 
			
		||||
                        uuid = UUIDHandler.getUUID(line, null);
 | 
			
		||||
                    }
 | 
			
		||||
                    if (uuid != null) {
 | 
			
		||||
                        MainUtil.sendMessage(null, " - &aFound plot: " + plot.id + " : " + line);
 | 
			
		||||
 
 | 
			
		||||
@@ -221,7 +221,7 @@ public class DebugExec extends SubCommand {
 | 
			
		||||
                    if (args.length != 2) {
 | 
			
		||||
                        return MainUtil.sendMessage(player, "Use /plot debugexec seen <player>");
 | 
			
		||||
                    }
 | 
			
		||||
                    final UUID uuid = UUIDHandler.getUUID(args[1]);
 | 
			
		||||
                    final UUID uuid = UUIDHandler.getUUID(args[1], null);
 | 
			
		||||
                    if (uuid == null) {
 | 
			
		||||
                        return MainUtil.sendMessage(player, "player not found: " + args[1]);
 | 
			
		||||
                    }
 | 
			
		||||
 
 | 
			
		||||
@@ -73,7 +73,7 @@ public class Deny extends SubCommand {
 | 
			
		||||
        if (args[0].equalsIgnoreCase("*")) {
 | 
			
		||||
            uuid = DBFunc.everyone;
 | 
			
		||||
        } else {
 | 
			
		||||
            uuid = UUIDHandler.getUUID(args[0]);
 | 
			
		||||
            uuid = UUIDHandler.getUUID(args[0], null);
 | 
			
		||||
        }
 | 
			
		||||
        if (uuid == null) {
 | 
			
		||||
            if (UUIDHandler.implementation instanceof SQLUUIDHandler) {
 | 
			
		||||
 
 | 
			
		||||
@@ -63,7 +63,7 @@ public class Purge extends SubCommand {
 | 
			
		||||
                caller.message("/plot purxe x;z &l<world>");
 | 
			
		||||
                return false;
 | 
			
		||||
            }
 | 
			
		||||
            final UUID uuid = UUIDHandler.getUUID(args[0]);
 | 
			
		||||
            final UUID uuid = UUIDHandler.getUUID(args[0], null);
 | 
			
		||||
            if (uuid != null) {
 | 
			
		||||
                caller.message("/plot purge " + args[0] + " &l<world>");
 | 
			
		||||
                return false;
 | 
			
		||||
@@ -149,7 +149,7 @@ public class Purge extends SubCommand {
 | 
			
		||||
            DBFunc.purge(worldname, ids);
 | 
			
		||||
            return finishPurge(length);
 | 
			
		||||
        }
 | 
			
		||||
        final UUID uuid = UUIDHandler.getUUID(args[0]);
 | 
			
		||||
        final UUID uuid = UUIDHandler.getUUID(args[0], null);
 | 
			
		||||
        if (uuid != null) {
 | 
			
		||||
            final Set<Plot> plots = PS.get().getPlots(worldname, uuid);
 | 
			
		||||
            final Set<PlotId> ids = new HashSet<>();
 | 
			
		||||
 
 | 
			
		||||
@@ -112,7 +112,7 @@ public class Remove extends SubCommand {
 | 
			
		||||
                break;
 | 
			
		||||
            }
 | 
			
		||||
            default:
 | 
			
		||||
                UUID uuid = UUIDHandler.getUUID(args[0]);
 | 
			
		||||
                UUID uuid = UUIDHandler.getUUID(args[0], null);
 | 
			
		||||
                if (uuid != null) {
 | 
			
		||||
                    if (plot.getTrusted().contains(uuid)) {
 | 
			
		||||
                        if (plot.removeTrusted(uuid)) {
 | 
			
		||||
 
 | 
			
		||||
@@ -56,7 +56,7 @@ public class SetOwner extends SubCommand {
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    private UUID getUUID(final String string) {
 | 
			
		||||
        return UUIDHandler.getUUID(string);
 | 
			
		||||
        return UUIDHandler.getUUID(string, null);
 | 
			
		||||
    }
 | 
			
		||||
 | 
			
		||||
    @Override
 | 
			
		||||
 
 | 
			
		||||
@@ -73,7 +73,7 @@ public class Trust extends SubCommand {
 | 
			
		||||
        if (args[0].equalsIgnoreCase("*")) {
 | 
			
		||||
            uuid = DBFunc.everyone;
 | 
			
		||||
        } else {
 | 
			
		||||
            uuid = UUIDHandler.getUUID(args[0]);
 | 
			
		||||
            uuid = UUIDHandler.getUUID(args[0], null);
 | 
			
		||||
        }
 | 
			
		||||
        if (uuid == null) {
 | 
			
		||||
            if (UUIDHandler.implementation instanceof SQLUUIDHandler) {
 | 
			
		||||
 
 | 
			
		||||
@@ -88,7 +88,7 @@ public class Undeny extends SubCommand {
 | 
			
		||||
                }
 | 
			
		||||
                break;
 | 
			
		||||
            default:
 | 
			
		||||
                UUID uuid = UUIDHandler.getUUID(args[0]);
 | 
			
		||||
                UUID uuid = UUIDHandler.getUUID(args[0], null);
 | 
			
		||||
                if (uuid != null) {
 | 
			
		||||
                    if (plot.removeDenied(uuid)) {
 | 
			
		||||
                        count++;
 | 
			
		||||
 
 | 
			
		||||
@@ -90,7 +90,7 @@ public class Untrust extends SubCommand {
 | 
			
		||||
                }
 | 
			
		||||
                break;
 | 
			
		||||
            default:
 | 
			
		||||
                UUID uuid = UUIDHandler.getUUID(args[0]);
 | 
			
		||||
                UUID uuid = UUIDHandler.getUUID(args[0], null);
 | 
			
		||||
                if (uuid != null) {
 | 
			
		||||
                    if (plot.removeTrusted(uuid)) {
 | 
			
		||||
                        count++;
 | 
			
		||||
 
 | 
			
		||||
@@ -66,7 +66,7 @@ public class Visit extends SubCommand {
 | 
			
		||||
    public boolean onCommand(CommandCaller caller, String[] args) {
 | 
			
		||||
        PlotPlayer plr = (PlotPlayer) caller.getSuperCaller();
 | 
			
		||||
        ArrayList<Plot> plots = new ArrayList<>();
 | 
			
		||||
        UUID user = UUIDHandler.getUUID(args[0]);
 | 
			
		||||
        UUID user = UUIDHandler.getUUID(args[0], null);
 | 
			
		||||
        if (user != null ) {
 | 
			
		||||
            // do plots by username
 | 
			
		||||
            plots.addAll(PS.get().getPlots(user));
 | 
			
		||||
 
 | 
			
		||||
@@ -301,7 +301,7 @@ public class list extends SubCommand {
 | 
			
		||||
                    plots = new ArrayList<>(PS.get().getPlots(args[0]).values());
 | 
			
		||||
                    break;
 | 
			
		||||
                }
 | 
			
		||||
                UUID uuid = UUIDHandler.getUUID(args[0]);
 | 
			
		||||
                UUID uuid = UUIDHandler.getUUID(args[0], null);
 | 
			
		||||
                if (uuid != null) {
 | 
			
		||||
                    if (!Permissions.hasPermission(plr, "plots.list.player")) {
 | 
			
		||||
                        MainUtil.sendMessage(plr, C.NO_PERMISSION, "plots.list.player");
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user