Skip to content

Commit 6bc022b

Browse files
committed
Remove errors.pos-protected-land message
The plugin that denied the event will usually send a more informative message.
1 parent c925016 commit 6bc022b

File tree

3 files changed

+1
-8
lines changed

3 files changed

+1
-8
lines changed

src/main/java/pro/cloudnode/smp/bankaccounts/BankConfig.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -650,11 +650,6 @@ public int invoiceNotifyInterval() {
650650
return MiniMessage.miniMessage().deserialize(Objects.requireNonNull(config.getString("messages.errors.pos-create-business-only")));
651651
}
652652

653-
// messages.errors.pos-protected-land
654-
public @NotNull Component messagesErrorsPosProtectedLand() {
655-
return MiniMessage.miniMessage().deserialize(Objects.requireNonNull(config.getString("messages.errors.pos-protected-land")));
656-
}
657-
658653
// messages.errors.disallowed-characters
659654
public @NotNull Component messagesErrorsDisallowedCharacters(final @NotNull Set<@NotNull String> characters) {
660655
return MiniMessage.miniMessage().deserialize(

src/main/java/pro/cloudnode/smp/bankaccounts/commands/POSCommand.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ public boolean execute(final @NotNull CommandSender sender, final @NotNull Strin
7777
if (!(block.get() instanceof final @NotNull Chest chest))
7878
return sendMessage(sender, BankAccounts.getInstance().config().messagesErrorsPosNotChest());
7979
if (!canOpenChest(player, chest))
80-
return sendMessage(sender, BankAccounts.getInstance().config().messagesErrorsPosProtectedLand());
80+
return true;
8181
if (chest.getInventory() instanceof DoubleChestInventory)
8282
return sendMessage(sender, BankAccounts.getInstance().config().messagesErrorsPosDoubleChest());
8383
if (chest.getInventory().isEmpty()) return sendMessage(sender, BankAccounts.getInstance().config().messagesErrorsPosEmpty());

src/main/resources/config.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -352,8 +352,6 @@ messages:
352352
no-card: "<red>(!) You must hold your bank card to use this.</red>"
353353
pos-items-changed: "<red>(!) The items in the chest have changed. POS cancelled.</red>"
354354
pos-create-business-only: "<red>(!) You can only create a POS with a business account.</red>"
355-
# Cannot create POS due to land protection
356-
pos-protected-land: "<red>(!) You don't own this chest; you cannot create a POS here."
357355
# Provided string includes disallowed characters
358356
# Placeholder: <characters> - the disallowed characters
359357
disallowed-characters: "<red>(!) The provided string contains disallowed characters: <gray><characters></gray></red>"

0 commit comments

Comments
 (0)