Move shutdown log to delayed actions
All checks were successful
continuous-integration/drone/push Build is passing
All checks were successful
continuous-integration/drone/push Build is passing
This commit is contained in:
parent
d15132e6d6
commit
70570624e1
@ -94,10 +94,10 @@ public class MessageListener extends ListenerAdapter
|
||||
MessageChannel channel = event.getChannel();
|
||||
|
||||
channel.sendMessage("Going to sleep! Cya :sparkles:").queue();
|
||||
logger.log("WARNING! Shutting down!");
|
||||
|
||||
Executors.newSingleThreadScheduledExecutor().schedule(() ->
|
||||
{
|
||||
logger.log("WARNING! Shutting down!");
|
||||
HidekoBot.getAPI().shutdown();
|
||||
System.exit(0);
|
||||
}, 5, TimeUnit.SECONDS);
|
||||
|
Loading…
Reference in New Issue
Block a user