summaryrefslogtreecommitdiff
path: root/ext/node/polyfills/_process/process.ts
diff options
context:
space:
mode:
authorLuca Casonato <hello@lcas.dev>2024-09-10 20:12:24 +0200
committerGitHub <noreply@github.com>2024-09-10 11:12:24 -0700
commit7bfcb4dd10d31f5f9566c90a28449c0951f3a48e (patch)
treefca0dec6e98118418f1712c6e8451a04c7e89988 /ext/node/polyfills/_process/process.ts
parentbe5419d479fcae16c8a07dec00ce11b532b7996a (diff)
feat(cli): use NotCapable error for permission errors (#25431)
Closes #7394 --------- Co-authored-by: snek <snek@deno.com>
Diffstat (limited to 'ext/node/polyfills/_process/process.ts')
-rw-r--r--ext/node/polyfills/_process/process.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/ext/node/polyfills/_process/process.ts b/ext/node/polyfills/_process/process.ts
index e4b88a11a..6f69139c9 100644
--- a/ext/node/polyfills/_process/process.ts
+++ b/ext/node/polyfills/_process/process.ts
@@ -53,8 +53,8 @@ function denoEnvGet(name: string) {
} catch (e) {
if (
ObjectPrototypeIsPrototypeOf(TypeErrorPrototype, e) ||
- // TODO(iuioiua): Use `PermissionDeniedPrototype` when it's available
- ObjectPrototypeIsPrototypeOf(Deno.errors.PermissionDenied.prototype, e)
+ // TODO(iuioiua): Use `NotCapablePrototype` when it's available
+ ObjectPrototypeIsPrototypeOf(Deno.errors.NotCapable.prototype, e)
) {
return undefined;
}