Skip to content
Open
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions src/drivers/fs.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,12 @@ export default defineDriver((userOptions: FSStorageOptions = {}) => {

const base = resolve(userOptions.base);

const ignore = anymatch(
userOptions.ignore || ["**/node_modules/**", "**/.git/**"]
);
const ignorePatterns = userOptions.ignore || [
"**/node_modules/**",
"**/.git/**",
];
const ignore = (path: string) =>
anymatch(ignorePatterns, path, { dot: true });

const r = (key: string) => {
if (PATH_TRAVERSE_RE.test(key)) {
Expand Down