aboutsummaryrefslogtreecommitdiff
path: root/azalea-auth/src
diff options
context:
space:
mode:
authormat <git@matdoes.dev>2024-11-27 10:26:40 +0000
committermat <git@matdoes.dev>2024-11-27 10:26:40 +0000
commit0817382098128adcecb77756a3c7cd1bd0066057 (patch)
tree623d9b297f9b5fdb2af74ab3c5a4fa5c1b72ff5b /azalea-auth/src
parentdfdc3144b61b6750ad62fb493b7c00c6c820c90b (diff)
downloadazalea-drasl-0817382098128adcecb77756a3c7cd1bd0066057.tar.xz
replace once_cell with std:;sync::LazyLock
Diffstat (limited to 'azalea-auth/src')
-rwxr-xr-xazalea-auth/src/sessionserver.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/azalea-auth/src/sessionserver.rs b/azalea-auth/src/sessionserver.rs
index 9c73fbf0..e7052e11 100755
--- a/azalea-auth/src/sessionserver.rs
+++ b/azalea-auth/src/sessionserver.rs
@@ -1,5 +1,6 @@
//! Tell Mojang you're joining a multiplayer server.
-use once_cell::sync::Lazy;
+use std::sync::LazyLock;
+
use reqwest::StatusCode;
use serde::Deserialize;
use serde_json::json;
@@ -49,7 +50,7 @@ pub struct ForbiddenError {
pub path: String,
}
-static REQWEST_CLIENT: Lazy<reqwest::Client> = Lazy::new(reqwest::Client::new);
+static REQWEST_CLIENT: LazyLock<reqwest::Client> = LazyLock::new(reqwest::Client::new);
/// Tell Mojang's servers that you are going to join a multiplayer server,
/// which is required to join online-mode servers. The server ID is an empty