Skip to content

Commit 1e03258

Browse files
Fix price change log recording wrong new price
1 parent 25d71ed commit 1e03258

File tree

1 file changed

+14
-5
lines changed

1 file changed

+14
-5
lines changed

src/main/java/org/maxgamer/quickshop/listener/InternalListener.java

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -27,15 +27,24 @@
2727
import org.bukkit.event.EventPriority;
2828
import org.jetbrains.annotations.NotNull;
2929
import org.maxgamer.quickshop.QuickShop;
30-
import org.maxgamer.quickshop.api.event.*;
30+
import org.maxgamer.quickshop.api.event.ShopCreateEvent;
31+
import org.maxgamer.quickshop.api.event.ShopDeleteEvent;
32+
import org.maxgamer.quickshop.api.event.ShopInventoryCalculateEvent;
33+
import org.maxgamer.quickshop.api.event.ShopModeratorChangedEvent;
34+
import org.maxgamer.quickshop.api.event.ShopPriceChangeEvent;
35+
import org.maxgamer.quickshop.api.event.ShopPurchaseEvent;
36+
import org.maxgamer.quickshop.api.event.ShopSuccessPurchaseEvent;
3137
import org.maxgamer.quickshop.shop.SimpleShopModerator;
3238
import org.maxgamer.quickshop.util.Util;
33-
import org.maxgamer.quickshop.util.logging.container.*;
39+
import org.maxgamer.quickshop.util.logging.container.PlayerEconomyPreCheckLog;
40+
import org.maxgamer.quickshop.util.logging.container.ShopCreationLog;
41+
import org.maxgamer.quickshop.util.logging.container.ShopModeratorChangedLog;
42+
import org.maxgamer.quickshop.util.logging.container.ShopPriceChangedLog;
43+
import org.maxgamer.quickshop.util.logging.container.ShopPurchaseLog;
44+
import org.maxgamer.quickshop.util.logging.container.ShopRemoveLog;
3445
import org.maxgamer.quickshop.util.reload.ReloadResult;
3546
import org.maxgamer.quickshop.util.reload.ReloadStatus;
3647

37-
import java.util.Objects;
38-
3948

4049
public class InternalListener extends AbstractQSListener {
4150
private final QuickShop plugin;
@@ -94,7 +103,7 @@ public void shopModeratorChanges(ShopModeratorChangedEvent event) {
94103
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true)
95104
public void shopPriceChanges(ShopPriceChangeEvent event) {
96105
if (loggingAction) {
97-
plugin.logEvent(new ShopPriceChangedLog(event.getShop().saveToInfoStorage(), event.getOldPrice(), event.getOldPrice()));
106+
plugin.logEvent(new ShopPriceChangedLog(event.getShop().saveToInfoStorage(), event.getOldPrice(), event.getNewPrice()));
98107
}
99108
}
100109

0 commit comments

Comments
 (0)