summaryrefslogtreecommitdiff
path: root/runtime/ops/process.rs
diff options
context:
space:
mode:
authorcrowlKats <13135287+crowlKats@users.noreply.github.com>2021-03-17 22:45:12 +0100
committerGitHub <noreply@github.com>2021-03-17 17:45:12 -0400
commit0e70d9e59bc0e70f1921bb217ee00fc2e6facb69 (patch)
treed501399bd07855148ce817c568e7228bdfd87d87 /runtime/ops/process.rs
parentb3fe85163f303a1592335b23c25554dd0e39a4c4 (diff)
refactor: clean up permission handling (#9367)
Diffstat (limited to 'runtime/ops/process.rs')
-rw-r--r--runtime/ops/process.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/runtime/ops/process.rs b/runtime/ops/process.rs
index 89f323232..a60b451eb 100644
--- a/runtime/ops/process.rs
+++ b/runtime/ops/process.rs
@@ -88,7 +88,7 @@ fn op_run(
_zero_copy: &mut [ZeroCopyBuf],
) -> Result<Value, AnyError> {
let run_args: RunArgs = serde_json::from_value(args)?;
- state.borrow::<Permissions>().check_run()?;
+ state.borrow::<Permissions>().run.check()?;
let args = run_args.cmd;
let env = run_args.env;
@@ -193,7 +193,7 @@ async fn op_run_status(
{
let s = state.borrow();
- s.borrow::<Permissions>().check_run()?;
+ s.borrow::<Permissions>().run.check()?;
}
let resource = state
@@ -285,7 +285,7 @@ fn op_kill(
_zero_copy: &mut [ZeroCopyBuf],
) -> Result<Value, AnyError> {
super::check_unstable(state, "Deno.kill");
- state.borrow::<Permissions>().check_run()?;
+ state.borrow::<Permissions>().run.check()?;
let args: KillArgs = serde_json::from_value(args)?;
kill(args.pid, args.signo)?;