forked from SteamWar/SteamWar
Format code
This commit is contained in:
@@ -64,7 +64,9 @@ public class CustomItem extends SpecialItem {
|
||||
|
||||
public static void init() {
|
||||
File itemsFolder = new File(MissileWars.getPlugin().getDataFolder(), "items");
|
||||
if (!itemsFolder.exists() || !itemsFolder.canRead() || !itemsFolder.isDirectory()) throw new SecurityException("Items could not be loaded");
|
||||
if (!itemsFolder.exists() || !itemsFolder.canRead() || !itemsFolder.isDirectory()) {
|
||||
throw new SecurityException("Items could not be loaded");
|
||||
}
|
||||
for (File itemFile : Objects.requireNonNull(itemsFolder.listFiles())) {
|
||||
if (!itemFile.canRead() || !itemFile.isFile()) continue;
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user