feat: added some minor logging
All checks were successful
On_Push / lint_fmt (push) Successful in 12s
On_Push / lint_clippy (push) Successful in 18s
On_Push / build (push) Successful in 1m27s
On_Push / deploy (push) Successful in 18s

This commit is contained in:
silver 2025-01-03 19:58:00 +00:00
parent b7d36de976
commit a9d3af024e
Signed by: silver
GPG key ID: 36F93D61BAD3FD7D
2 changed files with 7 additions and 4 deletions

View file

@ -328,7 +328,7 @@ pub(crate) mod server {
ID: {id} ID: {id}
Online: {online} Online: {online}
Info: {description} Info: {description}
Link: <http://panel.games.skynet.ie/server/{id}> Link: <https://panel.games.skynet.ie/server/{id}>
"#, "#,
name = &x.attributes.name, name = &x.attributes.name,
online = !x.attributes.is_suspended, online = !x.attributes.is_suspended,

View file

@ -774,7 +774,8 @@ struct BodyDelete {
} }
pub async fn whitelist_update(add: &Vec<(String, bool)>, server: &str, token: &str) { pub async fn whitelist_update(add: &Vec<(String, bool)>, server: &str, token: &str) {
let url_base = format!("http://panel.games.skynet.ie/api/client/servers/{server}"); println!("Update whitelist for {}", server);
let url_base = format!("https://panel.games.skynet.ie/api/client/servers/{server}");
let bearer = format!("Bearer {token}"); let bearer = format!("Bearer {token}");
for (name, java) in add { for (name, java) in add {
@ -792,7 +793,8 @@ pub async fn whitelist_update(add: &Vec<(String, bool)>, server: &str, token: &s
} }
pub async fn whitelist_wipe(server: &str, token: &str) { pub async fn whitelist_wipe(server: &str, token: &str) {
let url_base = format!("http://panel.games.skynet.ie/api/client/servers/{server}"); println!("Wiping whitelist for {}", server);
let url_base = format!("https://panel.games.skynet.ie/api/client/servers/{server}");
let bearer = format!("Bearer {token}"); let bearer = format!("Bearer {token}");
// delete whitelist // delete whitelist
@ -813,7 +815,8 @@ pub async fn whitelist_wipe(server: &str, token: &str) {
} }
pub async fn server_information(server: &str, token: &str) -> Option<ServerDetailsRes> { pub async fn server_information(server: &str, token: &str) -> Option<ServerDetailsRes> {
let url_base = format!("http://panel.games.skynet.ie/api/client/servers/{server}"); println!("Get server information for {}", server);
let url_base = format!("https://panel.games.skynet.ie/api/client/servers/{server}");
let bearer = format!("Bearer {token}"); let bearer = format!("Bearer {token}");
get::<ServerDetailsRes>(&format!("{url_base}/"), &bearer).await get::<ServerDetailsRes>(&format!("{url_base}/"), &bearer).await
} }