Fixed log spam when reading XML
This commit is contained in:
parent
666a3a6a50
commit
b1174bfad5
2 changed files with 9 additions and 9 deletions
|
@ -44,7 +44,7 @@ public class FillerManager {
|
|||
// directory is created by caller, so it can copy default files if any
|
||||
|
||||
if (!dir.isDirectory()) {
|
||||
throw new IllegalArgumentException("File path " + dir.getPath() + " must be a directory!");
|
||||
throw new IllegalArgumentException("File path " + dir.getName() + " must be a directory!");
|
||||
}
|
||||
|
||||
File[] files = dir.listFiles(new FilenameFilter() {
|
||||
|
@ -56,11 +56,11 @@ public class FillerManager {
|
|||
|
||||
for(File file : files) {
|
||||
try {
|
||||
WarpDrive.logger.info("Loading filler data file " + file.getPath() + "...");
|
||||
WarpDrive.logger.info("Loading filler data file " + file.getName() + "...");
|
||||
loadXmlFillerFile(file);
|
||||
WarpDrive.logger.info("Loading filler data file " + file.getPath() + " done");
|
||||
WarpDrive.logger.info("Loading filler data file " + file.getName() + " done");
|
||||
} catch (Exception exception) {
|
||||
WarpDrive.logger.error("Error loading file " + file.getPath() + ": " + exception.getMessage());
|
||||
WarpDrive.logger.error("Error loading file " + file.getName() + ": " + exception.getMessage());
|
||||
exception.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
@ -73,7 +73,7 @@ public class FillerManager {
|
|||
ModCheckResults res = XmlPreprocessor.checkModRequirements(base.getDocumentElement());
|
||||
|
||||
if (!res.isEmpty()) {
|
||||
WarpDrive.logger.info("Skippping filler data file " + file.getPath() + " because of: " + res);
|
||||
WarpDrive.logger.info("Skippping filler data file " + file.getName() + " because of: " + res);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -47,14 +47,14 @@ public class StructureManager {
|
|||
for (File file : files) {
|
||||
try {
|
||||
|
||||
WarpDrive.logger.info("Loading structure data file " + file.getPath());
|
||||
WarpDrive.logger.info("Loading structure data file " + file.getName());
|
||||
|
||||
loadXmlStructureFile(file);
|
||||
|
||||
WarpDrive.logger.info("Finished loading structure data file " + file.getPath());
|
||||
WarpDrive.logger.info("Finished loading structure data file " + file.getName());
|
||||
|
||||
} catch (Exception e) {
|
||||
WarpDrive.logger.error("Error loading file " + file.getPath() + ": " + e.getMessage());
|
||||
WarpDrive.logger.error("Error loading file " + file.getName() + ": " + e.getMessage());
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
@ -66,7 +66,7 @@ public class StructureManager {
|
|||
ModCheckResults res = XmlPreprocessor.checkModRequirements(base.getDocumentElement());
|
||||
|
||||
if (!res.isEmpty()) {
|
||||
WarpDrive.logger.info("Skippping structure data file " + f.getPath() + " because of: " + res);
|
||||
WarpDrive.logger.info("Skippping structure data file " + f.getName() + " because of: " + res);
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue