Fix Configurate conversions not saving

This commit is contained in:
Josh Roy 2021-07-02 16:23:44 -04:00
parent d903e40a53
commit 36a070be4c
1 changed files with 3 additions and 2 deletions

View File

@ -189,7 +189,7 @@ public class EssentialsUpgrade {
}
public void convertStupidCamelCaseUserdataKeys() {
if (doneFile.getBoolean("updateUsersLegacyPathNames", false)) {
if (doneFile.getBoolean("updateUsersStupidLegacyPathNames", false)) {
return;
}
@ -232,12 +232,13 @@ public class EssentialsUpgrade {
config.removeProperty("acceptingPay");
config.setProperty("accepting-pay", isPay);
}
config.blockingSave();
} catch (final RuntimeException ex) {
LOGGER.log(Level.INFO, "File: " + file.toString());
throw ex;
}
}
doneFile.setProperty("updateUsersLegacyPathNames", true);
doneFile.setProperty("updateUsersStupidLegacyPathNames", true);
doneFile.save();
LOGGER.info("Done converting legacy userdata keys to Configurate.");
}