From 98866d2c6d3675482acce42d2b9a76100dd6785c Mon Sep 17 00:00:00 2001 From: Presti Date: Tue, 9 Aug 2022 14:35:52 +0200 Subject: [PATCH] * Shutdown on error * Version bump --- pom.xml | 2 +- src/main/java/de/presti/ree6/main/Main.java | 7 +++++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/pom.xml b/pom.xml index e15e1222c..5a3478b51 100644 --- a/pom.xml +++ b/pom.xml @@ -10,7 +10,7 @@ de.presti Ree6 - 1.9.2 + 1.9.3 jar diff --git a/src/main/java/de/presti/ree6/main/Main.java b/src/main/java/de/presti/ree6/main/Main.java index 2c30c2d3a..c846e5d35 100644 --- a/src/main/java/de/presti/ree6/main/Main.java +++ b/src/main/java/de/presti/ree6/main/Main.java @@ -130,7 +130,7 @@ public static void main(String[] args) { // Create a RayGun Client to send Exception to an external Service for Bug fixing. Thread.setDefaultUncaughtExceptionHandler((t, e) -> { RaygunClient raygunClient = new RaygunClient(instance.config.getConfiguration().getString("raygun.apitoken")); - raygunClient.setVersion("1.9.2"); + raygunClient.setVersion("1.9.3"); }); // Create a new connection between the Application and the SQL-Server. @@ -143,6 +143,7 @@ public static void main(String[] args) { instance.commandManager = new CommandManager(); } catch (Exception exception) { instance.logger.error("Shutting down, because of an critical error!", exception); + System.exit(0); return; } @@ -173,11 +174,13 @@ public static void main(String[] args) { // Create a new Instance of the Bot, as well as add the Events. try { - BotWorker.createBot(BotVersion.RELEASE, "1.9.2"); + BotWorker.createBot(BotVersion.RELEASE, "1.9.3"); instance.musicWorker = new MusicWorker(); instance.addEvents(); } catch (Exception ex) { instance.logger.error("[Main] Error while init: " + ex.getMessage()); + System.exit(0); + return; } // Add the Runtime-hooks.