From 847f22f63fe6031936de8f9b32aa6cea76ee010a Mon Sep 17 00:00:00 2001 From: Jikoo Date: Wed, 11 Sep 2024 11:33:30 -0400 Subject: [PATCH] Fix containers not being notified when owner joins --- .../main/java/com/lishid/openinv/util/InventoryManager.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/plugin/src/main/java/com/lishid/openinv/util/InventoryManager.java b/plugin/src/main/java/com/lishid/openinv/util/InventoryManager.java index 4210777a..deebb1ec 100644 --- a/plugin/src/main/java/com/lishid/openinv/util/InventoryManager.java +++ b/plugin/src/main/java/com/lishid/openinv/util/InventoryManager.java @@ -111,7 +111,10 @@ public void unload(@NotNull UUID uuid) { @Keep @EventHandler(priority = EventPriority.LOWEST) private void onPlayerJoin(@NotNull PlayerJoinEvent event) { - consumeLoaded(event.getPlayer().getUniqueId(), inventory -> checkViewerAccess(inventory, true)); + consumeLoaded(event.getPlayer().getUniqueId(), inventory -> { + inventory.setPlayerOnline(event.getPlayer()); + checkViewerAccess(inventory, true); + }); } @Keep