From 6ff717031008f66320addb8c9ff5dcf1b93e31b0 Mon Sep 17 00:00:00 2001 From: Chaoscaot Date: Sun, 17 Sep 2023 23:00:14 +0200 Subject: [PATCH] Fix Change Type --- .../commands/schematiccommand/SchematicValidator.java | 2 +- .../commands/schematiccommand/parts/ModifyPart.java | 1 - 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/SchematicSystem_Core/src/de/steamwar/schematicsystem/commands/schematiccommand/SchematicValidator.java b/SchematicSystem_Core/src/de/steamwar/schematicsystem/commands/schematiccommand/SchematicValidator.java index 0b66476..e6bff1d 100644 --- a/SchematicSystem_Core/src/de/steamwar/schematicsystem/commands/schematiccommand/SchematicValidator.java +++ b/SchematicSystem_Core/src/de/steamwar/schematicsystem/commands/schematiccommand/SchematicValidator.java @@ -80,7 +80,7 @@ public class SchematicValidator { if(!nodeNullCheck(messageSender, schematicNode)) { return false; } - if(schematicNode.getOwner() != SteamwarUser.get(((Player) commandSender).getUniqueId()).getId()) { + if(schematicNode.getOwner() != SchematicCommandUtils.getUser((Player) commandSender).getId()) { messageSender.send("COMMAND_NOT_OWN"); return false; } diff --git a/SchematicSystem_Core/src/de/steamwar/schematicsystem/commands/schematiccommand/parts/ModifyPart.java b/SchematicSystem_Core/src/de/steamwar/schematicsystem/commands/schematiccommand/parts/ModifyPart.java index a9f3799..cee2cbc 100644 --- a/SchematicSystem_Core/src/de/steamwar/schematicsystem/commands/schematiccommand/parts/ModifyPart.java +++ b/SchematicSystem_Core/src/de/steamwar/schematicsystem/commands/schematiccommand/parts/ModifyPart.java @@ -47,7 +47,6 @@ public class ModifyPart extends SWCommand { @Register("changetype") public void changeType(Player player, @Validator("isOwnerSchematicValidator") SchematicNode node) { - SteamwarUser user = getUser(player); TextComponent base = new TextComponent(); Clipboard clipboard = null;