+2
Cargo.lock
+2
Cargo.lock
···
89
89
"softbuffer",
90
90
"tiny-skia",
91
91
"tokio",
92
+
"tokio-rustls",
92
93
"tokio-tungstenite-wasm",
93
94
"tokio-websockets",
94
95
"wasm-bindgen-futures",
···
1638
1639
checksum = "c0ebcbd2f03de0fc1122ad9bb24b127a5a6cd51d72604a3f3c50ac459762b6cc"
1639
1640
dependencies = [
1640
1641
"once_cell",
1642
+
"ring",
1641
1643
"rustls-pki-types",
1642
1644
"rustls-webpki",
1643
1645
"subtle",
+2
Cargo.toml
+2
Cargo.toml
···
15
15
"dep:tokio-websockets",
16
16
]
17
17
client = [
18
+
"dep:tokio-rustls",
18
19
"dep:tokio-tungstenite-wasm",
19
20
]
20
21
···
38
39
wasm-bindgen-futures = "0.4"
39
40
40
41
[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
42
+
tokio-rustls = { optional = true, version = "0.26", default-features = false, features = ["ring"] }
41
43
enigo = { optional = true, version = "0.5.0", features = ["wayland"] }
42
44
tokio = { version = "1", default-features = false, features = ["rt", "rt-multi-thread", "sync"] }
43
45
ahash = { version = "0.8", default-features = false, features = ["runtime-rng"] }
+2
src/main.rs
+2
src/main.rs
···
543
543
});
544
544
#[cfg(feature = "client")]
545
545
{
546
+
#[cfg(not(any(target_arch = "wasm32", target_arch = "wasm64")))]
547
+
let _ = tokio_rustls::rustls::crypto::ring::default_provider().install_default();
546
548
let client_id = app.client_id;
547
549
let fut = async move {
548
550
ws::client::connect(env!("SERVER_URL"), window, _rx, _tx, client_id)