From 1da7782d2ca83b4e3af8c00ac20bcb9f83f50218 Mon Sep 17 00:00:00 2001 From: omegaui Date: Sat, 25 Mar 2023 19:08:19 +0530 Subject: [PATCH] =?UTF-8?q?=F0=9F=9A=80=20Reformatted=20Code!?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/main/java/omegaui/io/storage/FileUtils.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/omegaui/io/storage/FileUtils.java b/src/main/java/omegaui/io/storage/FileUtils.java index 216d647..2335386 100644 --- a/src/main/java/omegaui/io/storage/FileUtils.java +++ b/src/main/java/omegaui/io/storage/FileUtils.java @@ -70,7 +70,7 @@ public static String read(File file){ public static boolean write(File file, String content){ File parent = file.getParentFile(); if(parent != null) { - if(!parent.mkdirs()){ + if(!parent.exists() && !parent.mkdirs()){ System.err.println("Cannot construct the parent directories: " + file); return false; }