diff --git a/src/main/java/ca/tweetzy/auctionhouse/guis/transaction/GUITransactionType.java b/src/main/java/ca/tweetzy/auctionhouse/guis/transaction/GUITransactionType.java index afd5a6d..52df36a 100644 --- a/src/main/java/ca/tweetzy/auctionhouse/guis/transaction/GUITransactionType.java +++ b/src/main/java/ca/tweetzy/auctionhouse/guis/transaction/GUITransactionType.java @@ -27,6 +27,11 @@ public final class GUITransactionType extends Gui { private void draw() { setButton(11, ConfigurationItemHelper.createConfigurationItem(Settings.GUI_TRANSACTIONS_TYPE_ITEMS_ALL_TRANSACTIONS_ITEM.getString(), Settings.GUI_TRANSACTIONS_TYPE_ITEMS_ALL_TRANSACTIONS_NAME.getString(), Settings.GUI_TRANSACTIONS_TYPE_ITEMS_ALL_TRANSACTIONS_LORE.getStringList(), null), e -> { + if (Settings.RESTRICT_ALL_TRANSACTIONS_TO_PERM.getBoolean() && !e.player.hasPermission("auctionhouse.transactions.viewall")) { + AuctionHouse.getInstance().getLocale().getMessage("commands.no_permission").sendPrefixedMessage(e.player); + return; + } + e.manager.showGUI(e.player, new GUITransactionList(e.player, true)); });