summaryrefslogtreecommitdiff
path: root/std
diff options
context:
space:
mode:
Diffstat (limited to 'std')
-rw-r--r--std/fs/_util.ts6
1 files changed, 1 insertions, 5 deletions
diff --git a/std/fs/_util.ts b/std/fs/_util.ts
index aecd9748b..bae48c970 100644
--- a/std/fs/_util.ts
+++ b/std/fs/_util.ts
@@ -16,11 +16,7 @@ export function isSubdir(
}
const srcArray = src.split(sep);
const destArray = dest.split(sep);
- // see: https://github.com/Microsoft/TypeScript/issues/30821
- // @ts-ignore
- return srcArray.reduce((acc: true, current: string, i: number): boolean => {
- return acc && destArray[i] === current;
- }, true);
+ return srcArray.every((current, i) => destArray[i] === current);
}
export type PathType = "file" | "dir" | "symlink";