stupid lines of cleanup

This commit is contained in:
2024-11-08 20:15:04 -07:00
parent 011b66423a
commit 6c808694db
3 changed files with 7 additions and 10 deletions
+2 -2
View File
@@ -26,12 +26,12 @@ ogg = "0.9.1"
ordermap = "0.5.3"
html-purifier = "0.3.0"
markdown = "0.3.0"
gloo-timers = { version = "0.3.0", features = ["futures"] }
gloo-timers = { version = "0.3.0", features = ["futures"], optional = true }
futures-channel = "0.3.30"
sir = { version = "0.5.0", features = ["dioxus"] }
tokio = { version = "1.41.1", features = ["net", "rt"], optional = true }
tokio-rustls = { version = "0.26.0", optional = true }
[features]
web = ["dioxus/web", "dioxus-web", "wasm-bindgen", "wasm-bindgen-futures", "wasm-streams", "serde-wasm-bindgen", "js-sys", "web-sys"]
web = ["dioxus/web", "dioxus-web", "wasm-bindgen", "wasm-bindgen-futures", "wasm-streams", "serde-wasm-bindgen", "js-sys", "web-sys", "gloo-timers"]
desktop = ["dioxus/desktop", "tokio", "tokio-rustls"]
+4 -2
View File
@@ -20,7 +20,6 @@ pub enum Command {
Connect {
address: String,
username: String,
hash: String,
},
SendChat {
markdown: String,
@@ -348,7 +347,10 @@ pub fn LoginView() -> Element {
);
let do_connect = move |_| {
net.send(Connect{address: address.read().clone(), username: username.read().clone(), hash: "[39, 96, 204, 127, 26, 59, 35, 209, 197, 103, 192, 6, 3, 98, 203, 228, 124, 46, 247, 72, 44, 224, 123, 238, 218, 140, 128, 100, 115, 14, 23, 233]".to_string()})
net.send(Connect {
address: address.read().clone(),
username: username.read().clone(),
})
};
let status = &STATE.status;
let bottom = match &*status.read() {
+1 -6
View File
@@ -41,12 +41,7 @@ macro_rules! bail {
pub async fn network_entrypoint(mut event_rx: UnboundedReceiver<Command>) {
loop {
let Some(Command::Connect {
address,
username,
hash,
}) = event_rx.next().await
else {
let Some(Command::Connect { address, username }) = event_rx.next().await else {
panic!("Did not receive connect command")
};