Move Data After Storage Changed, Closes #75

After someone reloads the plugin and they've switched the storage system
then put the data, if any exists, into the new storage system. This
means a player can go from flatfile to mysql or from mysql to flatfile
without having to do any manual work.
This commit is contained in:
graywolf336
2015-05-27 12:26:31 -05:00
parent 55062bc03a
commit afa051b1b2
2 changed files with 37 additions and 20 deletions

View File

@ -161,7 +161,7 @@ public class Jail {
/** Adds a cell to the Jail. */
public boolean addCell(Cell cell, boolean save) {
if(save) plugin.getJailIO().saveCell(this, cell);
if(save) plugin.getJailIO().saveCell(this, cell, false);
//Check if it already exists or not
if(this.cells.containsKey(cell.getName())) return false;