diff --git a/pom.xml b/pom.xml
index 00f886a..331f67b 100644
--- a/pom.xml
+++ b/pom.xml
@@ -6,7 +6,7 @@
de.flexusma
JDA-CMDH
- 1.0.5+b2
+ 1.0.5+b5
diff --git a/src/main/java/de/flexusma/jdacmdh/database/Database.java b/src/main/java/de/flexusma/jdacmdh/database/Database.java
index 91e7f82..0648d1f 100644
--- a/src/main/java/de/flexusma/jdacmdh/database/Database.java
+++ b/src/main/java/de/flexusma/jdacmdh/database/Database.java
@@ -147,15 +147,17 @@ public static CommandPreferences prefFromDB(Connection connection,
public static CommandPreferences initPref(JDA jda, String id){
try {
return Database.prefFromDB(Database.getCon(), id);
+ }catch (SQLException e) {
+ Logger.log(LogType.WARN, "SQL Error: " + e.getErrorCode() + " " + e.getMessage());
+
}catch (Exception e){
- Logger.log(LogType.WARN,e.getMessage());
try {
prefToDB(Database.getCon(),id,new CommandPreferences());
} catch (SQLException ex) {
Logger.log(LogType.WARN,ex.getMessage());
}
- return new CommandPreferences();
}
+ return new CommandPreferences();
}
public static void savePref(JDA jda, String id, CommandPreferences pref){
@@ -163,7 +165,7 @@ public static void savePref(JDA jda, String id, CommandPreferences pref){
try {
prefToDB(Database.getCon(),id,pref);
} catch (SQLException e) {
- Logger.log(LogType.WARN,e.getMessage());
+ Logger.log(LogType.WARN, "SQL Error: "+e.getErrorCode()+" "+e.getMessage());
try {
uprefToDB(Database.getCon(),id,pref);
} catch (SQLException e1) {
diff --git a/target/JDA-CMDH-1.0.5+b3.jar b/target/JDA-CMDH-1.0.5+b3.jar
new file mode 100644
index 0000000..93df217
Binary files /dev/null and b/target/JDA-CMDH-1.0.5+b3.jar differ
diff --git a/target/JDA-CMDH-1.0.5+b4-shaded.jar b/target/JDA-CMDH-1.0.5+b4-shaded.jar
new file mode 100644
index 0000000..5733a7b
Binary files /dev/null and b/target/JDA-CMDH-1.0.5+b4-shaded.jar differ
diff --git a/target/JDA-CMDH-1.0.5+b4.jar b/target/JDA-CMDH-1.0.5+b4.jar
new file mode 100644
index 0000000..5733a7b
Binary files /dev/null and b/target/JDA-CMDH-1.0.5+b4.jar differ
diff --git a/target/JDA-CMDH-1.0.5+b5.jar b/target/JDA-CMDH-1.0.5+b5.jar
new file mode 100644
index 0000000..df65166
Binary files /dev/null and b/target/JDA-CMDH-1.0.5+b5.jar differ
diff --git a/target/maven-archiver/pom.properties b/target/maven-archiver/pom.properties
index 3725c78..81f5489 100644
--- a/target/maven-archiver/pom.properties
+++ b/target/maven-archiver/pom.properties
@@ -1,4 +1,4 @@
#Created by Apache Maven 3.6.1
groupId=de.flexusma
artifactId=JDA-CMDH
-version=1.0.5+b2
+version=1.0.5+b5
diff --git a/target/original-JDA-CMDH-1.0.5+b3.jar b/target/original-JDA-CMDH-1.0.5+b3.jar
new file mode 100644
index 0000000..e9c6fa8
Binary files /dev/null and b/target/original-JDA-CMDH-1.0.5+b3.jar differ
diff --git a/target/original-JDA-CMDH-1.0.5+b4.jar b/target/original-JDA-CMDH-1.0.5+b4.jar
new file mode 100644
index 0000000..984e1c6
Binary files /dev/null and b/target/original-JDA-CMDH-1.0.5+b4.jar differ
diff --git a/target/original-JDA-CMDH-1.0.5+b5.jar b/target/original-JDA-CMDH-1.0.5+b5.jar
new file mode 100644
index 0000000..25359ec
Binary files /dev/null and b/target/original-JDA-CMDH-1.0.5+b5.jar differ