mirror of
https://github.com/lacerta-doc/Lacerta.git
synced 2024-11-26 09:43:15 +00:00
fix
This commit is contained in:
parent
27aa6a2f15
commit
c05d45afdd
|
@ -174,8 +174,10 @@ public class FileManagerImpl implements FileManager {
|
||||||
public FileManager createFile() throws IOException {
|
public FileManager createFile() throws IOException {
|
||||||
try {
|
try {
|
||||||
if (this.autoCreateParent) {
|
if (this.autoCreateParent) {
|
||||||
|
if (!this.path.getParent().toFile().exists()) {
|
||||||
Files.createDirectories(this.path.getParent());
|
Files.createDirectories(this.path.getParent());
|
||||||
}
|
}
|
||||||
|
}
|
||||||
Files.createFile(this.path);
|
Files.createFile(this.path);
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
logger.error("createFile", e.getMessage());
|
logger.error("createFile", e.getMessage());
|
||||||
|
|
Loading…
Reference in New Issue
Block a user