Dieser Commit ist enthalten in:
Ursprung
56227a4a9f
Commit
49cfb11bf1
@ -55,6 +55,7 @@ import net.md_5.bungee.config.YamlConfiguration;
|
|||||||
import java.io.File;
|
import java.io.File;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.net.InetSocketAddress;
|
import java.net.InetSocketAddress;
|
||||||
|
import java.time.Duration;
|
||||||
import java.util.Collection;
|
import java.util.Collection;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@ -224,6 +225,10 @@ public class BungeeCore extends Plugin {
|
|||||||
if (SteamwarDiscordBotConfig.loaded) {
|
if (SteamwarDiscordBotConfig.loaded) {
|
||||||
try {
|
try {
|
||||||
SteamwarDiscordBot.instance().getJda().shutdown();
|
SteamwarDiscordBot.instance().getJda().shutdown();
|
||||||
|
if(!SteamwarDiscordBot.instance().getJda().awaitShutdown(Duration.ofSeconds(10))) {
|
||||||
|
SteamwarDiscordBot.instance().getJda().shutdownNow();
|
||||||
|
SteamwarDiscordBot.instance().getJda().awaitShutdown();
|
||||||
|
}
|
||||||
} catch (Throwable e) {
|
} catch (Throwable e) {
|
||||||
getLogger().log(Level.SEVERE, "Could not shutdown discord bot", e);
|
getLogger().log(Level.SEVERE, "Could not shutdown discord bot", e);
|
||||||
}
|
}
|
||||||
|
@ -19,6 +19,7 @@
|
|||||||
|
|
||||||
package de.steamwar.bungeecore.bot.commands;
|
package de.steamwar.bungeecore.bot.commands;
|
||||||
|
|
||||||
|
import de.steamwar.bungeecore.commands.PunishmentCommand;
|
||||||
import de.steamwar.sql.BannedUserIPs;
|
import de.steamwar.sql.BannedUserIPs;
|
||||||
import de.steamwar.sql.Punishment;
|
import de.steamwar.sql.Punishment;
|
||||||
import de.steamwar.sql.SteamwarUser;
|
import de.steamwar.sql.SteamwarUser;
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren