Fixed comment update

This commit is contained in:
boy0001 2015-04-16 23:37:50 +10:00
parent 689583334d
commit c44bf77f32

View File

@ -589,6 +589,15 @@ public class SQLManager implements AbstractDB {
rs = data.getColumns(null, null, this.prefix + "plot_comments", "hashcode");
if (!rs.next()) {
rs.close();
try {
final Statement statement = this.connection.createStatement();
statement.addBatch("ALTER IGNORE TABLE `" + this.prefix + "plot_comments` ADD `inbox` VARCHAR(11) DEFAULT `public`");
statement.addBatch("ALTER IGNORE TABLE `" + this.prefix + "plot_comments` ADD `timestamp` INT(11) DEFAULT 0");
statement.addBatch("ALTER TABLE `" + this.prefix + "plot` DROP `tier`");
statement.executeBatch();
statement.close();
}
catch (SQLException e) {
final Statement statement = this.connection.createStatement();
statement.addBatch("DROP TABLE `" + this.prefix + "plot_comments`");
if (PlotSquared.getMySQL() != null) {
@ -601,6 +610,7 @@ public class SQLManager implements AbstractDB {
statement.close();
}
}
}
rs.close();
}
catch (SQLException e) {