fix(smartfs.provider.node): Default createDirectory to recursive=true when option not provided in Node provider

This commit is contained in:
2025-11-30 18:10:25 +00:00
parent 5577e4e4de
commit 3bdb014d25
3 changed files with 9 additions and 2 deletions

View File

@@ -3,6 +3,6 @@
*/
export const commitinfo = {
name: '@push.rocks/smartfs',
version: '1.1.2',
version: '1.1.3',
description: 'a cross platform extendable fs module'
}

View File

@@ -237,7 +237,7 @@ export class SmartFsProviderNode implements ISmartFsProvider {
public async createDirectory(path: string, options?: { recursive?: boolean; mode?: number }): Promise<void> {
await fs.mkdir(path, {
recursive: options?.recursive,
recursive: options?.recursive ?? true,
mode: options?.mode,
});
}