Skip to content

Commit

Permalink
feat: inline createDirectories now that non-existent path throws IOEx…
Browse files Browse the repository at this point in the history
…ception during reader construction (#89)
  • Loading branch information
cmhulbert committed Jan 3, 2023
1 parent 1cc8d1c commit c1abdfc
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions src/main/java/org/janelia/saalfeldlab/n5/N5FSWriter.java
Original file line number Diff line number Diff line change
Expand Up @@ -73,8 +73,7 @@ public class N5FSWriter extends N5FSReader implements N5Writer {
*/
public N5FSWriter(final String basePath, final GsonBuilder gsonBuilder) throws IOException {

super(basePath, gsonBuilder);
createDirectories(Paths.get(basePath));
super(createDirectories(Paths.get(basePath)).toString(), gsonBuilder);
if (!VERSION.equals(getVersion()))
setAttribute("/", VERSION_KEY, VERSION.toString());
}
Expand Down

0 comments on commit c1abdfc

Please sign in to comment.