1
0
Fork 0
gallery-dl-archive-manager/lib/io.js
2024-02-09 20:43:24 -05:00

6 lines
210 B
JavaScript

import { readdir } from 'fs/promises'
export const getChildren = async source =>
(await readdir(source, { withFileTypes: true }))
.filter(dirent => dirent.isDirectory())
.map(dirent => dirent.name)