clear it on close/open just in case

This commit is contained in:
Ryder Belserion 2024-09-12 21:03:30 -04:00
parent 422325f07a
commit 569f317c7a
No known key found for this signature in database

View File

@ -99,6 +99,16 @@ public class AuctionMenu extends DynamicInventoryBuilder {
this.menus.clear();
}, this.gui);
this.gui.setOpenGuiAction(event -> {
// Clear again, just in case.
this.menus.clear();
});
this.gui.setCloseGuiAction(event -> {
// forget the data, so no memory leak!
this.menus.clear();
});
this.gui.open(this.player);
}
}