Skip to content

Commit

Permalink
Oof
Browse files Browse the repository at this point in the history
  • Loading branch information
The Judge committed Sep 17, 2024
1 parent 415a569 commit 8c15489
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/main/java/pojlib/util/FileUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,9 @@ public static void write(String path, byte[] content) throws IOException
{
File outPath = new File(path);
Objects.requireNonNull(outPath.getParentFile()).mkdirs();
if(!outPath.exists()) {
outPath.createNewFile();
}

BufferedOutputStream fos = new BufferedOutputStream(Files.newOutputStream(outPath.toPath()));
fos.write(content, 0, content.length);
Expand Down

0 comments on commit 8c15489

Please sign in to comment.