1
0
Dieser Commit ist enthalten in:
Lixfel 2021-06-09 06:20:42 +02:00
Ursprung 5b11f133fa
Commit 2e0627242c

Datei anzeigen

@ -22,6 +22,7 @@ package net.md_5.bungee.api.bungeepluginmanager;
import net.md_5.bungee.api.event.AsyncEvent;
import net.md_5.bungee.api.plugin.Plugin;
import net.md_5.bungee.event.EventBus;
import net.md_5.bungee.event.EventExceptionHandler;
import java.util.Collections;
import java.util.Set;
@ -45,13 +46,13 @@ public final class ModifiedPluginEventBus extends EventBus {
}
@Override
public void post(Object event) {
public <T> void post(T event, EventExceptionHandler<T> exceptionHandler) {
if (event instanceof AsyncEvent) {
synchronized (LOCK) {
UNCOMPLETED_EVENTS.add((AsyncEvent<?>) event);
}
}
super.post(event);
super.post(event, exceptionHandler);
}
}