Replace deprecated package
All checks were successful
Build and push container image / build (push) Successful in 7m13s

This commit is contained in:
toast 2024-01-02 14:42:40 +11:00
parent fd2e330a15
commit 8c4f409e37
3 changed files with 10 additions and 9 deletions

8
Cargo.lock generated
View File

@ -794,11 +794,11 @@ dependencies = [
[[package]]
name = "kon"
version = "0.1.5"
version = "0.1.6"
dependencies = [
"cargo_toml",
"gamedig",
"lazy_static",
"once_cell",
"poise",
"reqwest",
"serde_json",
@ -951,9 +951,9 @@ dependencies = [
[[package]]
name = "once_cell"
version = "1.18.0"
version = "1.19.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d"
checksum = "3fdb12b2476b595f9358c5161aa467c2438859caa136dec86c26fdd2efe17b92"
[[package]]
name = "openssl"

View File

@ -1,6 +1,6 @@
[package]
name = "kon"
version = "0.1.5"
version = "0.1.6"
rust-version = "1.74"
edition = "2021"
@ -9,7 +9,7 @@ edition = "2021"
[dependencies]
cargo_toml = "0.17.2"
gamedig = "0.4.1"
lazy_static = "1.4.0"
once_cell = "1.19.0"
poise = "0.5.7"
reqwest = "0.11.23"
serde_json = "1.0.109"

View File

@ -18,13 +18,14 @@ use reqwest::{
Client,
header::USER_AGENT
};
use once_cell::sync::Lazy;
use cargo_toml::Manifest;
use serde_json::Value;
use tokio::join;
lazy_static::lazy_static! {
static ref PMS_BASE: String = var("WG_PMS").expect("Expected a \"WG_PMS\" in the envvar but none was found");
}
static PMS_BASE: Lazy<String> = Lazy::new(||
var("WG_PMS").expect("Expected a \"WG_PMS\" in the envvar but none was found")
);
fn query_server() -> Result<Response, Error> {
let server_ip = var("ATS_SERVER_IP").expect("Expected a \"ATS_SERVER_IP\" in the envvar but none was found");