Adds json suffix to JSON database files

https://github.com/BentoBoxWorld/BentoBox/issues/502
This commit is contained in:
tastybento 2019-01-29 13:43:34 -08:00
parent 7b79755d92
commit 271d6aa5e9

View File

@ -99,7 +99,7 @@ public class JSONDatabaseHandler<T> extends AbstractJSONDatabaseHandler<T> {
// Obtain the value of uniqueId within the instance (which must be a DataObject)
PropertyDescriptor propertyDescriptor = new PropertyDescriptor("uniqueId", dataObject);
Method method = propertyDescriptor.getReadMethod();
String fileName = (String) method.invoke(instance);
String fileName = (String) method.invoke(instance) + JSON;
File tableFolder = new File(plugin.getDataFolder(), path);
File file = new File(tableFolder, fileName);