summaryrefslogtreecommitdiff
path: root/ext/node/polyfills/internal
diff options
context:
space:
mode:
Diffstat (limited to 'ext/node/polyfills/internal')
-rw-r--r--ext/node/polyfills/internal/errors.ts13
1 files changed, 13 insertions, 0 deletions
diff --git a/ext/node/polyfills/internal/errors.ts b/ext/node/polyfills/internal/errors.ts
index 55098d79b..2ba7ec28e 100644
--- a/ext/node/polyfills/internal/errors.ts
+++ b/ext/node/polyfills/internal/errors.ts
@@ -2497,6 +2497,19 @@ export class ERR_FS_RMDIR_ENOTDIR extends NodeSystemError {
}
}
+export class ERR_OS_NO_HOMEDIR extends NodeSystemError {
+ constructor() {
+ const code = isWindows ? "ENOENT" : "ENOTDIR";
+ const ctx: NodeSystemErrorCtx = {
+ message: "not a directory",
+ syscall: "home",
+ code,
+ errno: isWindows ? osConstants.errno.ENOENT : osConstants.errno.ENOTDIR,
+ };
+ super(code, ctx, "Path is not a directory");
+ }
+}
+
interface UvExceptionContext {
syscall: string;
path?: string;