diff --git a/paper/src/main/java/com/badbones69/crazyauctions/api/guis/types/AuctionsMenu.java b/paper/src/main/java/com/badbones69/crazyauctions/api/guis/types/AuctionsMenu.java index f95d6b4..3afde1b 100644 --- a/paper/src/main/java/com/badbones69/crazyauctions/api/guis/types/AuctionsMenu.java +++ b/paper/src/main/java/com/badbones69/crazyauctions/api/guis/types/AuctionsMenu.java @@ -81,6 +81,10 @@ public class AuctionsMenu extends Holder { getItems(); // populates the lists + int maxPage = Methods.getMaxPage(this.items); + + for (;this.page > maxPage; this.page--); + HolderManager.addShopType(this.player, this.shopType); switch (this.shopType) { diff --git a/paper/src/main/java/com/badbones69/crazyauctions/api/guis/types/CurrentMenu.java b/paper/src/main/java/com/badbones69/crazyauctions/api/guis/types/CurrentMenu.java index 6c535e7..1b4a8e5 100644 --- a/paper/src/main/java/com/badbones69/crazyauctions/api/guis/types/CurrentMenu.java +++ b/paper/src/main/java/com/badbones69/crazyauctions/api/guis/types/CurrentMenu.java @@ -60,6 +60,10 @@ public class CurrentMenu extends Holder { getItems(); + int maxPage = Methods.getMaxPage(this.items); + + for (;this.page > maxPage; this.page--); + for (final String key : this.options) { if (!this.config.contains("Settings.GUISettings.OtherSettings." + key)) { continue;