Skip to content

Commit 882e2b7

Browse files
committed
refactor(js-runtime): drop unused async-trait from JsRuntimeProvider
The trait has no async methods, so the attribute generated nothing. Remove it and the async-trait dependency from vp_js_runtime.
1 parent a583efa commit 882e2b7

4 files changed

Lines changed: 0 additions & 6 deletions

File tree

Cargo.lock

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

crates/vp_js_runtime/Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ publish = false
88
rust-version.workspace = true
99

1010
[dependencies]
11-
async-trait = { workspace = true }
1211
backon = { workspace = true }
1312
flate2 = { workspace = true }
1413
futures-util = { workspace = true }

crates/vp_js_runtime/src/provider.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
//! This module defines the trait that all runtime providers (Node, Bun, Deno)
44
//! must implement, along with types for describing download information.
55
6-
use async_trait::async_trait;
76
use vt_str::Str;
87

98
use crate::{Error, Platform};
@@ -77,7 +76,6 @@ pub struct DownloadInfo {
7776
///
7877
/// Each runtime (Node.js, Bun, Deno) implements this trait to provide
7978
/// runtime-specific logic for downloading and installing.
80-
#[async_trait]
8179
pub trait JsRuntimeProvider: Send + Sync {
8280
/// Get the name of this runtime (e.g., "node", "bun", "deno")
8381
fn name(&self) -> &'static str;

crates/vp_js_runtime/src/providers/node.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
33
use std::time::{SystemTime, UNIX_EPOCH};
44

5-
use async_trait::async_trait;
65
use node_semver::{Range, Version};
76
use serde::{Deserialize, Serialize};
87
use vt_path::{AbsolutePath, AbsolutePathBuf};
@@ -590,7 +589,6 @@ fn is_official_dist_host(base_url: &str) -> bool {
590589
host.eq_ignore_ascii_case("nodejs.org")
591590
}
592591

593-
#[async_trait]
594592
impl JsRuntimeProvider for NodeProvider {
595593
fn name(&self) -> &'static str {
596594
"node"

0 commit comments

Comments
 (0)