diff options
Diffstat (limited to 'ozone/src/auth.rs')
| -rw-r--r-- | ozone/src/auth.rs | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/ozone/src/auth.rs b/ozone/src/auth.rs index 712bd4d..2387ada 100644 --- a/ozone/src/auth.rs +++ b/ozone/src/auth.rs @@ -13,7 +13,7 @@ use oauth2::basic::{BasicErrorResponse, BasicErrorResponseType, BasicRevocationE use reqwest::{IntoUrl, Method, RequestBuilder}; pub use types::*; use crate::auth::msa::{XSTS_RP_MINECRAFT_SERVICES, XSTS_RP_XBOX_LIVE}; -use crate::util::USER_AGENT; +use crate::util; #[derive(Debug)] pub enum AuthError { @@ -96,13 +96,12 @@ const NON_AZURE_LOGIN_SCOPES: &[&str] = ["service::user.auth.xboxlive.com::MBI_S fn build_json_request(client: &reqwest::Client, url: impl IntoUrl, method: Method) -> RequestBuilder { client.request(method, url) - .header(reqwest::header::USER_AGENT, USER_AGENT) .header(reqwest::header::ACCEPT, "application/json") } impl MsaUser { pub fn create_client() -> reqwest::Client { - reqwest::ClientBuilder::new() + util::build_client() .redirect(reqwest::redirect::Policy::none()) .build().expect("building client should succeed") } |
