mirror of
https://github.com/ChestShop-authors/ChestShop-3.git
synced 2024-12-18 06:17:46 +01:00
Fix NPE on file load
This commit is contained in:
parent
a02593bd4c
commit
e0fbe9f31a
@ -126,7 +126,10 @@ public class ChestShop extends JavaPlugin {
|
||||
private static File loadFile(File file) {
|
||||
if (!file.exists()) {
|
||||
try {
|
||||
if (file.getParent() != null) {
|
||||
file.getParentFile().mkdirs();
|
||||
}
|
||||
|
||||
file.createNewFile();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
|
Loading…
Reference in New Issue
Block a user