2019-06-14 04:27:40 +02:00
|
|
|
From 6f396335289763e35a0fc5293654713c15ea1df2 Mon Sep 17 00:00:00 2001
|
2016-02-24 07:32:44 +01:00
|
|
|
From: Aikar <aikar@aikar.co>
|
2016-03-01 00:09:49 +01:00
|
|
|
Date: Mon, 29 Feb 2016 20:26:39 -0600
|
2016-02-24 07:32:44 +01:00
|
|
|
Subject: [PATCH] Fix ServerListPingEvent flagging as Async
|
|
|
|
|
|
|
|
This event can sometimes fire Async, set the proper boolean
|
|
|
|
|
|
|
|
diff --git a/src/main/java/org/bukkit/event/server/ServerEvent.java b/src/main/java/org/bukkit/event/server/ServerEvent.java
|
2019-06-06 17:36:57 +02:00
|
|
|
index 46b119017..05167fb34 100644
|
2016-02-24 07:32:44 +01:00
|
|
|
--- a/src/main/java/org/bukkit/event/server/ServerEvent.java
|
|
|
|
+++ b/src/main/java/org/bukkit/event/server/ServerEvent.java
|
2019-04-23 06:47:07 +02:00
|
|
|
@@ -1,5 +1,6 @@
|
2016-02-24 07:32:44 +01:00
|
|
|
package org.bukkit.event.server;
|
|
|
|
|
|
|
|
+import org.bukkit.Bukkit;
|
|
|
|
import org.bukkit.event.Event;
|
|
|
|
|
|
|
|
/**
|
2019-04-23 06:47:07 +02:00
|
|
|
@@ -8,7 +9,7 @@ import org.bukkit.event.Event;
|
2016-02-24 07:32:44 +01:00
|
|
|
public abstract class ServerEvent extends Event {
|
|
|
|
|
2019-04-23 06:47:07 +02:00
|
|
|
public ServerEvent() {
|
|
|
|
- super();
|
|
|
|
+ super(!Bukkit.isPrimaryThread()); // Paper
|
|
|
|
}
|
|
|
|
|
|
|
|
public ServerEvent(boolean isAsync) {
|
2016-02-24 07:32:44 +01:00
|
|
|
--
|
2019-03-20 01:28:15 +01:00
|
|
|
2.21.0
|
2016-02-24 07:32:44 +01:00
|
|
|
|