From cf8d83afd5860994cbec9dee5abeb56d56815806 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 13 Apr 2026 06:47:22 +0000 Subject: [PATCH 1/2] Initial plan From 45b9d4eb0f73a809dca82e40e4628dc54a8cd9a1 Mon Sep 17 00:00:00 2001 From: "copilot-swe-agent[bot]" <198982749+Copilot@users.noreply.github.com> Date: Mon, 13 Apr 2026 06:51:04 +0000 Subject: [PATCH 2/2] Fix island chat to use isLogIslandChats() and [Island Chat Log] prefix Agent-Logs-Url: https://github.com/BentoBoxWorld/Chat/sessions/12e3f697-a2ad-4956-a392-972c6517d421 Co-authored-by: tastybento <4407265+tastybento@users.noreply.github.com> --- .../java/world/bentobox/chat/listeners/ChatListener.java | 4 ++-- .../world/bentobox/chat/listeners/ChatListenerTest.java | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/src/main/java/world/bentobox/chat/listeners/ChatListener.java b/src/main/java/world/bentobox/chat/listeners/ChatListener.java index 7a2300e..2657963 100644 --- a/src/main/java/world/bentobox/chat/listeners/ChatListener.java +++ b/src/main/java/world/bentobox/chat/listeners/ChatListener.java @@ -148,8 +148,8 @@ public void islandChat(Island i, Player player, String message) { // Send message to island .forEach(u -> u.sendMessage("chat.island-chat.syntax", TextVariables.NAME, player.getName(), MESSAGE, message)); // Log if required - if (addon.getSettings().isLogTeamChats()) { - addon.log("[Team Chat Log] " + player.getName() + ": " + message); + if (addon.getSettings().isLogIslandChats()) { + addon.log("[Island Chat Log] " + player.getName() + ": " + message); } // Spy if required Bukkit.getOnlinePlayers().stream() diff --git a/src/test/java/world/bentobox/chat/listeners/ChatListenerTest.java b/src/test/java/world/bentobox/chat/listeners/ChatListenerTest.java index e33531d..0501a88 100644 --- a/src/test/java/world/bentobox/chat/listeners/ChatListenerTest.java +++ b/src/test/java/world/bentobox/chat/listeners/ChatListenerTest.java @@ -321,16 +321,16 @@ public void testTeamChatDoesNotLogWhenDisabled() { @Test public void testIslandChatLogsWhenEnabled() { - when(settings.isLogTeamChats()).thenReturn(true); + when(settings.isLogIslandChats()).thenReturn(true); mockedBukkit.when(org.bukkit.Bukkit::getOnlinePlayers).thenReturn(Collections.emptyList()); listener.islandChat(island, player, "island log message"); - verify(addon).log("[Team Chat Log] tastybento: island log message"); + verify(addon).log("[Island Chat Log] tastybento: island log message"); } @Test public void testIslandChatDoesNotLogWhenDisabled() { - when(settings.isLogTeamChats()).thenReturn(false); + when(settings.isLogIslandChats()).thenReturn(false); mockedBukkit.when(org.bukkit.Bukkit::getOnlinePlayers).thenReturn(Collections.emptyList()); listener.islandChat(island, player, "island silent message");