misc: refactor and code hygine #12

Merged
joshuafhiggins merged 4 commits from misc-refactor-and-code-hygine into main 2025-12-31 05:35:23 +00:00
Showing only changes of commit 46db2f7cc8 - Show all commits

View File

@@ -125,6 +125,8 @@ async fn handle_connection(
error!("handle_player_list: {}", e);
let _ = send(&tx, e.to_string().as_str());
}
} else {
let _ = send(&tx, "ERROR:INVALID:PLAYER");
}
}
"GAME" => {
@@ -159,6 +161,8 @@ async fn handle_connection(
let _ = send(&tx, "ERROR:INVALID:TERMINATE");
}
}
} else {
let _ = send(&tx, "ERROR:INVALID:GAME");
}
}
"ADMIN" => {
@@ -174,6 +178,8 @@ async fn handle_connection(
error!("handle_admin_kick: {}", e);
let _ = send(&tx, e.to_string().as_str());
}
} else {
let _ = send(&tx, "ERROR:INVALID:ADMIN");
}
}
"TOURNAMENT" => {
@@ -201,6 +207,8 @@ async fn handle_connection(
let _ = send(&tx, "ERROR:INVALID:TOURNAMENT");
}
}
} else {
let _ = send(&tx, "ERROR:INVALID:TOURNAMENT");
}
}
"GET" => {
@@ -214,6 +222,8 @@ async fn handle_connection(
error!("handle_get_tournament_status: {}", e);
let _ = send(&tx, e.to_string().as_str());
}
} else {
let _ = send(&tx, "ERROR:INVALID:GET");
}
}
_ => {