From b36ccc137f3a0f40c004c5bed9d519f676ed6f8d Mon Sep 17 00:00:00 2001 From: gnembon Date: Tue, 21 Jul 2020 12:10:41 -0300 Subject: [PATCH] fixed issue with command events --- src/main/java/carpet/script/CarpetEventServer.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/carpet/script/CarpetEventServer.java b/src/main/java/carpet/script/CarpetEventServer.java index 8ccf25be..ed661156 100644 --- a/src/main/java/carpet/script/CarpetEventServer.java +++ b/src/main/java/carpet/script/CarpetEventServer.java @@ -193,7 +193,7 @@ public class CarpetEventServer public void removeEventCall(String hostName, String funName) { - callList.removeIf((c)-> c.function.getString().equals(funName) && ( hostName == null || c.host.equalsIgnoreCase(hostName) ) ); + callList.removeIf((c)-> c.function.getString().equals(funName) && ( hostName == c.host || (c.host != null && c.host.equalsIgnoreCase(hostName) )) ); } public void removeAllCalls(String hostName)