mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2025-03-11 14:20:54 +01:00
Catch database init error on move
This commit is contained in:
parent
8939148f95
commit
5ebc722d43
@ -245,12 +245,12 @@ public class DatabaseCommands {
|
||||
}
|
||||
|
||||
private void performMove(CMDSender sender, DBType fromDB, DBType toDB) {
|
||||
Database fromDatabase = dbSystem.getActiveDatabaseByType(fromDB);
|
||||
Database toDatabase = dbSystem.getActiveDatabaseByType(toDB);
|
||||
fromDatabase.init();
|
||||
toDatabase.init();
|
||||
|
||||
try {
|
||||
Database fromDatabase = dbSystem.getActiveDatabaseByType(fromDB);
|
||||
Database toDatabase = dbSystem.getActiveDatabaseByType(toDB);
|
||||
fromDatabase.init();
|
||||
toDatabase.init();
|
||||
|
||||
sender.send("Writing to " + toDB.getName() + "..");
|
||||
|
||||
fromDatabase.executeTransaction(new BackupCopyTransaction(fromDatabase, toDatabase)).get();
|
||||
|
Loading…
Reference in New Issue
Block a user