1
0
Эх сурвалжийг харах

Added check for if a chat message got canceled by another plugin.

FlorianKem 6 жил өмнө
parent
commit
a29edfcf7c

+ 2 - 0
src/main/java/de/Linus122/TelegramChat/Main.java

@@ -192,6 +192,8 @@ public class Main extends JavaPlugin implements Listener {
 	public void onChat(AsyncPlayerChatEvent e) {
 		if (!this.getConfig().getBoolean("enable-chatmessages"))
 			return;
+		if(e.isCancelled())
+			return;
 		if (telegramHook.connected) {
 			ChatMessageToTelegram chat = new ChatMessageToTelegram();
 			chat.parse_mode = "Markdown";