using newer MySQL driver

- Newer driver doesn't need manual loading
- Fixes #1783
This commit is contained in:
BrainStone 2018-03-10 21:34:11 +01:00
parent 8f5e2eb439
commit 515405aa9e

View File

@ -42,8 +42,7 @@ public class MySQL extends Database {
}
@Override
public Connection forceConnection() throws SQLException, ClassNotFoundException {
Class.forName("com.mysql.jdbc.Driver");
public Connection forceConnection() throws SQLException {
this.connection =
DriverManager.getConnection("jdbc:mysql://" + this.hostname + ':' + this.port + '/' + this.database + "?" + StringMan.join(Storage.MySQL.PROPERTIES, "&"), this.user, this.password);
return this.connection;