diff options
author | Aaron O'Mullan <aaron.omullan@gmail.com> | 2022-03-22 16:39:58 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-22 16:39:58 +0100 |
commit | f81334d5bd1df723b1543dd906bd5672808bc75f (patch) | |
tree | f0cfe6da3c6078170a714d52272243ca647e119d /core/examples/disable_ops.rs | |
parent | c9817c335c23a5b85d6262b0e42abef19075c975 (diff) |
feat(core): disableable extensions & ops (#14063)
Streamlines a common middleware pattern and provides foundations for avoiding variably sized v8::ExternalReferences & enabling fully monomorphic op callpaths
Diffstat (limited to 'core/examples/disable_ops.rs')
-rw-r--r-- | core/examples/disable_ops.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/core/examples/disable_ops.rs b/core/examples/disable_ops.rs index 7421961d4..c1473b193 100644 --- a/core/examples/disable_ops.rs +++ b/core/examples/disable_ops.rs @@ -9,7 +9,7 @@ use deno_core::RuntimeOptions; fn main() { let my_ext = Extension::builder() .middleware(|op| match op.name { - "op_print" => deno_core::op_void_sync::decl(), + "op_print" => op.disable(), _ => op, }) .build(); |