fixed a problem where a directory already existed

This commit is contained in:
Nebel 2023-12-24 22:59:13 +09:00
parent 2130778667
commit bf83e1cf0b
Signed by: nebel
GPG Key ID: 79807D08C6EF6460
2 changed files with 2 additions and 2 deletions

View File

@ -1,6 +1,6 @@
{
"name": "@fogtype/gadl",
"version": "1.4.1",
"version": "1.4.2",
"license": "AGPL-3.0",
"type": "module",
"bin": "bin/run.js",

View File

@ -43,7 +43,7 @@ export function createPlatform(opts: {
...platform,
async download(dir: string, book: Book): Promise<void> {
await fs.mkdir(dir);
await fs.mkdir(dir, { recursive: true });
const files: Array<() => Promise<Blob>> = await platform.getFiles(book);
const digits = String(files.length).length;