Skip to content

Commit

Permalink
fixed reportPath issue
Browse files Browse the repository at this point in the history
  • Loading branch information
melaasar committed Sep 15, 2022
1 parent 9dcccb2 commit aaafe1e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
subprojects {
group = 'io.opencaesar.owl'
version = '1.0.7'
version = '1.0.8'

ext.versions = [
owl: '5.1.17',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -648,12 +648,11 @@ public static class ReportPathValidator implements IParameterValidator {
@Override
public void validate(final String name, final String value) throws ParameterException {
File file = new File(value);
if (!file.exists() || !file.getName().endsWith(".xml")) {
if (!file.getName().endsWith(".xml")) {
throw new ParameterException("Parameter " + name + " should be a valid XML path");
}
File parentFile = file.getParentFile();
if (parentFile != null && !parentFile.exists()) {
//noinspection ResultOfMethodCallIgnored
parentFile.mkdirs();
}
}
Expand Down

0 comments on commit aaafe1e

Please sign in to comment.