summaryrefslogtreecommitdiff
path: root/cli/ops/dispatch_json.rs
diff options
context:
space:
mode:
Diffstat (limited to 'cli/ops/dispatch_json.rs')
-rw-r--r--cli/ops/dispatch_json.rs12
1 files changed, 0 insertions, 12 deletions
diff --git a/cli/ops/dispatch_json.rs b/cli/ops/dispatch_json.rs
index 031e10c51..e28c32382 100644
--- a/cli/ops/dispatch_json.rs
+++ b/cli/ops/dispatch_json.rs
@@ -119,15 +119,3 @@ where
}
}
}
-
-pub fn blocking_json<F>(is_sync: bool, f: F) -> Result<JsonOp, ErrBox>
-where
- F: 'static + Send + FnOnce() -> JsonResult,
-{
- if is_sync {
- Ok(JsonOp::Sync(f()?))
- } else {
- let fut = async move { tokio::task::spawn_blocking(f).await.unwrap() };
- Ok(JsonOp::Async(fut.boxed_local()))
- }
-}