mirror of
https://github.com/lacerta-doc/Lacerta.git
synced 2024-11-23 00:13:16 +00:00
createFileの場合でも親ディレクトリを生成するように
This commit is contained in:
parent
360580eff2
commit
4cf3ff5f3c
|
@ -173,6 +173,9 @@ public class FileManagerImpl implements FileManager {
|
||||||
@Override
|
@Override
|
||||||
public FileManager createFile() throws IOException {
|
public FileManager createFile() throws IOException {
|
||||||
try {
|
try {
|
||||||
|
if (this.autoCreateParent) {
|
||||||
|
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