mirror of
https://github.com/funkemunky/AntiVPN.git
synced 2026-05-31 09:31:54 +00:00
Merge pull request #15 from unbeproducoes/patch-1
Try to use the new MySQL driver first.
This commit is contained in:
@@ -12,7 +12,11 @@ public class MySQL {
|
||||
public static void init() {
|
||||
try {
|
||||
if (conn == null || conn.isClosed()) {
|
||||
Class.forName("com.mysql.jdbc.Driver");
|
||||
try {
|
||||
Class.forName("com.mysql.cj.jdbc.Driver");
|
||||
} catch (ClassNotFoundException e) {
|
||||
Class.forName("com.mysql.jdbc.Driver");
|
||||
}
|
||||
conn = DriverManager.getConnection("jdbc:mysql://" + AntiVPN.getInstance().getConfig().getIp()
|
||||
+ ":" + AntiVPN.getInstance().getConfig().getPort()
|
||||
+ "/?useSSL=true&autoReconnect=true",
|
||||
|
||||
Reference in New Issue
Block a user