summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--csarvalidation/src/main/java/org/onap/validation/csar/FileUtil.java6
1 files changed, 5 insertions, 1 deletions
diff --git a/csarvalidation/src/main/java/org/onap/validation/csar/FileUtil.java b/csarvalidation/src/main/java/org/onap/validation/csar/FileUtil.java
index 45c8db1..07dece1 100644
--- a/csarvalidation/src/main/java/org/onap/validation/csar/FileUtil.java
+++ b/csarvalidation/src/main/java/org/onap/validation/csar/FileUtil.java
@@ -50,8 +50,12 @@ public final class FileUtil {
int tryCount = 0;
while (tryCount < TRY_COUNT) {
tryCount++;
- if (folder.exists() || folder.mkdirs()) {
+ if (folder.exists()) {
return true;
+ } else {
+ if (folder.mkdirs()) {
+ return true;
+ }
}
}