diff options
Diffstat (limited to 'fs/ensure_symlink.ts')
| -rw-r--r-- | fs/ensure_symlink.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/ensure_symlink.ts b/fs/ensure_symlink.ts index fbb89948e..09452a8ce 100644 --- a/fs/ensure_symlink.ts +++ b/fs/ensure_symlink.ts @@ -2,7 +2,7 @@ import * as path from "./path/mod.ts"; import { ensureDir, ensureDirSync } from "./ensure_dir.ts"; import { exists, existsSync } from "./exists.ts"; -import { PathType, getFileInfoType } from "./utils.ts"; +import { getFileInfoType } from "./utils.ts"; const isWindows = Deno.platform.os === "win"; @@ -20,7 +20,7 @@ export async function ensureSymlink(src: string, dest: string): Promise<void> { if (await exists(dest)) { const destStatInfo = await Deno.lstat(dest); const destFilePathType = getFileInfoType(destStatInfo); - if (destFilePathType !== PathType.symlink) { + if (destFilePathType !== "symlink") { throw new Error( `Ensure path exists, expected 'symlink', got '${destFilePathType}'` ); @@ -52,7 +52,7 @@ export function ensureSymlinkSync(src: string, dest: string): void { if (existsSync(dest)) { const destStatInfo = Deno.lstatSync(dest); const destFilePathType = getFileInfoType(destStatInfo); - if (destFilePathType !== PathType.symlink) { + if (destFilePathType !== "symlink") { throw new Error( `Ensure path exists, expected 'symlink', got '${destFilePathType}'` ); |
