Oops. Fix NPE

This commit is contained in:
kashike
2016-02-06 12:13:41 -08:00
parent aaef544ea4
commit 06bb39d345
@@ -276,7 +276,8 @@ public class UUIDVaultManager {
}
File file = new File(this.directory, uniqueId.toString() + ".yml");
if (!file.exists() && createIfNotFound) {
if (!file.exists()) {
if (createIfNotFound) {
try {
file.createNewFile();
} catch (IOException e) {
@@ -285,6 +286,7 @@ public class UUIDVaultManager {
} else {
return null;
}
}
return YamlConfiguration.loadConfiguration(file);
}