From 2388da62a50cc9a61833d52a25860d526b21f3c3 Mon Sep 17 00:00:00 2001 From: Phoenix616 Date: Sun, 8 Oct 2023 20:55:38 +0100 Subject: [PATCH] Log tax messages to the shop logger too This makes it possible to turn these messages off or reroute them to the shop log file --- .../Acrobot/ChestShop/Listeners/Economy/TaxModule.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/com/Acrobot/ChestShop/Listeners/Economy/TaxModule.java b/src/main/java/com/Acrobot/ChestShop/Listeners/Economy/TaxModule.java index e1872d7..b4264cb 100644 --- a/src/main/java/com/Acrobot/ChestShop/Listeners/Economy/TaxModule.java +++ b/src/main/java/com/Acrobot/ChestShop/Listeners/Economy/TaxModule.java @@ -57,20 +57,20 @@ public class TaxModule implements Listener { NameManager.getServerEconomyAccount().getUuid(), event.getWorld())); } - ChestShop.getBukkitLogger().info(String.format(TAX_RECEIVED_MESSAGE, taxAmount, tax, taxedAmount)); + ChestShop.getShopLogger().info(String.format(TAX_RECEIVED_MESSAGE, taxAmount, tax, taxedAmount)); } } else if (event.getDirection() == CurrencyTransferEvent.Direction.PARTNER && Permission.has(event.getInitiator(), Permission.NO_BUY_TAX)) { // Reduce paid amount as the buyer has permission to not pay taxes BigDecimal taxSent = getTaxAmount(event.getAmountSent(), taxAmount); BigDecimal taxedSentAmount = event.getAmountSent().subtract(taxSent); event.setAmountSent(taxedSentAmount); - ChestShop.getBukkitLogger().info(String.format(TAX_SENT_MESSAGE, taxAmount, taxSent, taxedSentAmount)); + ChestShop.getShopLogger().info(String.format(TAX_SENT_MESSAGE, taxAmount, taxSent, taxedSentAmount)); // Reduce the amount that the seller receives anyways even though tax wasn't paid as that shouldn't make a difference for the seller BigDecimal taxReceived = getTaxAmount(event.getAmountReceived(), taxAmount); BigDecimal taxedReceivedAmount = event.getAmountReceived().subtract(taxReceived); event.setAmountReceived(taxedReceivedAmount); - ChestShop.getBukkitLogger().info(String.format(TAX_RECEIVED_MESSAGE, taxAmount, taxReceived, taxedReceivedAmount)); + ChestShop.getShopLogger().info(String.format(TAX_RECEIVED_MESSAGE, taxAmount, taxReceived, taxedReceivedAmount)); } } -} +} \ No newline at end of file