From b32a6f8ad20e6e4b0cc24b8256c08192b4899844 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bartek=20Iwa=C5=84czuk?= Date: Tue, 7 Mar 2023 17:37:37 -0400 Subject: refactor(core): don't use Result in ExtensionBuilder::state (#18066) There's no point for this API to expect result. If something fails it should result in a panic during build time to signal to embedder that setup is wrong. --- cli/ops/bench.rs | 1 - cli/ops/mod.rs | 1 - cli/ops/testing.rs | 1 - 3 files changed, 3 deletions(-) (limited to 'cli/ops') diff --git a/cli/ops/bench.rs b/cli/ops/bench.rs index 2181a139c..513ecc0d1 100644 --- a/cli/ops/bench.rs +++ b/cli/ops/bench.rs @@ -38,7 +38,6 @@ pub fn init( .state(move |state| { state.put(sender.clone()); state.put(filter.clone()); - Ok(()) }) .build() } diff --git a/cli/ops/mod.rs b/cli/ops/mod.rs index c31a30531..53f74ad1f 100644 --- a/cli/ops/mod.rs +++ b/cli/ops/mod.rs @@ -18,7 +18,6 @@ fn init_proc_state(ps: ProcState) -> Extension { .ops(vec![op_npm_process_state::decl()]) .state(move |state| { state.put(ps.clone()); - Ok(()) }) .build() } diff --git a/cli/ops/testing.rs b/cli/ops/testing.rs index e9d0acf41..9170e9400 100644 --- a/cli/ops/testing.rs +++ b/cli/ops/testing.rs @@ -44,7 +44,6 @@ pub fn init( state.put(sender.clone()); state.put(fail_fast_tracker.clone()); state.put(filter.clone()); - Ok(()) }) .build() } -- cgit v1.2.3